--- old/make/copy/Copy-java.base.gmk 2017-10-25 08:03:34.657647471 -0400 +++ new/make/copy/Copy-java.base.gmk 2017-10-25 08:03:34.241599352 -0400 @@ -42,7 +42,7 @@ $(call install-file) $(INCLUDE_DST_OS_DIR)/%.h: \ - $(TOPDIR)/src/java.base/$(OPENJDK_TARGET_OS_EXPORT_DIR)/native/include/%.h + $(TOPDIR)/src/java.base/$(OPENJDK_TARGET_OS_TYPE)/native/include/%.h $(call install-file) ################################################################################ --- old/make/hotspot/lib/CompileJvm.gmk 2017-10-25 08:03:44.062461911 -0400 +++ new/make/hotspot/lib/CompileJvm.gmk 2017-10-25 08:03:43.623300789 -0400 @@ -57,8 +57,8 @@ $(patsubst %,-I%,$(filter-out $(JVM_VARIANT_OUTPUTDIR)/gensrc/%, $(JVM_SRC_DIRS))) \ -I$(JVM_VARIANT_OUTPUTDIR)/gensrc \ -I$(TOPDIR)/src/hotspot/share/precompiled \ - -I$(TOPDIR)/src/hotspot/share/prims \ -I$(TOPDIR)/src/java.base/share/native/include \ + -I$(TOPDIR)/src/java.base/$(OPENJDK_TARGET_OS_TYPE)/native/include \ # # INCLUDE_SUFFIX_* is only meant for including the proper --- old/make/hotspot/lib/CompileLibjsig.gmk 2017-10-25 08:03:52.103804562 -0400 +++ new/make/hotspot/lib/CompileLibjsig.gmk 2017-10-25 08:03:51.756227251 -0400 @@ -57,7 +57,7 @@ endif else ifeq ($(OPENJDK_TARGET_OS), solaris) - LIBJSIG_CFLAGS := -m64 -KPIC -mt -I $(TOPDIR)/src/hotspot/os/solaris + LIBJSIG_CFLAGS := -m64 -KPIC -mt -I $(TOPDIR)/src/java.base/unix/native/include LIBJSIG_LDFLAGS := -m64 -mt -xnolib LIBJSIG_LIBS := $(LIBDL) --- old/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp 2017-10-25 08:04:02.181932352 -0400 +++ new/src/hotspot/cpu/aarch64/macroAssembler_aarch64.cpp 2017-10-25 08:04:01.636211936 -0400 @@ -26,6 +26,7 @@ #include #include "precompiled.hpp" +#include "jvm.h" #include "asm/assembler.hpp" #include "asm/assembler.inline.hpp" #include "interpreter/interpreter.hpp" @@ -38,7 +39,6 @@ #include "opto/compile.hpp" #include "opto/intrinsicnode.hpp" #include "opto/node.hpp" -#include "prims/jvm.h" #include "runtime/biasedLocking.hpp" #include "runtime/icache.hpp" #include "runtime/interfaceSupport.hpp" --- old/src/hotspot/cpu/arm/interp_masm_arm.cpp 2017-10-25 08:04:10.863306350 -0400 +++ new/src/hotspot/cpu/arm/interp_masm_arm.cpp 2017-10-25 08:04:10.441624735 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "gc/shared/barrierSet.inline.hpp" #include "gc/shared/cardTableModRefBS.inline.hpp" #include "gc/shared/collectedHeap.hpp" --- old/src/hotspot/cpu/arm/methodHandles_arm.cpp 2017-10-25 08:04:19.089949324 -0400 +++ new/src/hotspot/cpu/arm/methodHandles_arm.cpp 2017-10-25 08:04:18.737548769 -0400 @@ -27,12 +27,12 @@ // Last synchronization: changeset f8c9417e3571 #include "precompiled.hpp" +#include "jvm.h" #include "classfile/javaClasses.inline.hpp" #include "interpreter/interpreter.hpp" #include "interpreter/interpreterRuntime.hpp" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #define __ _masm-> --- old/src/hotspot/cpu/arm/vm_version_arm_32.cpp 2017-10-25 08:04:27.333025867 -0400 +++ new/src/hotspot/cpu/arm/vm_version_arm_32.cpp 2017-10-25 08:04:26.984983503 -0400 @@ -23,9 +23,9 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/java.hpp" #include "runtime/os.inline.hpp" #include "runtime/stubCodeGenerator.hpp" --- old/src/hotspot/cpu/arm/vm_version_arm_64.cpp 2017-10-25 08:04:35.889694233 -0400 +++ new/src/hotspot/cpu/arm/vm_version_arm_64.cpp 2017-10-25 08:04:35.566984860 -0400 @@ -23,9 +23,9 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/java.hpp" #include "runtime/os.inline.hpp" #include "runtime/stubCodeGenerator.hpp" --- old/src/hotspot/cpu/ppc/methodHandles_ppc.cpp 2017-10-25 08:04:44.303679634 -0400 +++ new/src/hotspot/cpu/ppc/methodHandles_ppc.cpp 2017-10-25 08:04:43.871040138 -0400 @@ -24,12 +24,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.inline.hpp" #include "classfile/javaClasses.inline.hpp" #include "interpreter/interpreter.hpp" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #define __ _masm-> --- old/src/hotspot/cpu/ppc/vm_version_ppc.cpp 2017-10-25 08:04:52.506889949 -0400 +++ new/src/hotspot/cpu/ppc/vm_version_ppc.cpp 2017-10-25 08:04:52.171189869 -0400 @@ -24,11 +24,11 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/assembler.inline.hpp" #include "asm/macroAssembler.inline.hpp" #include "compiler/disassembler.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/java.hpp" #include "runtime/os.hpp" #include "runtime/stubCodeGenerator.hpp" --- old/src/hotspot/cpu/s390/methodHandles_s390.cpp 2017-10-25 08:05:00.924602571 -0400 +++ new/src/hotspot/cpu/s390/methodHandles_s390.cpp 2017-10-25 08:05:00.424224940 -0400 @@ -24,12 +24,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.inline.hpp" #include "classfile/javaClasses.inline.hpp" #include "interpreter/interpreter.hpp" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #ifdef PRODUCT --- old/src/hotspot/cpu/s390/vm_version_s390.cpp 2017-10-25 08:05:09.767896440 -0400 +++ new/src/hotspot/cpu/s390/vm_version_s390.cpp 2017-10-25 08:05:09.304012440 -0400 @@ -24,11 +24,11 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/assembler.inline.hpp" #include "compiler/disassembler.hpp" #include "code/compiledIC.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/java.hpp" #include "runtime/stubCodeGenerator.hpp" #include "vm_version_s390.hpp" --- old/src/hotspot/cpu/sparc/macroAssembler_sparc.cpp 2017-10-25 08:05:18.568781443 -0400 +++ new/src/hotspot/cpu/sparc/macroAssembler_sparc.cpp 2017-10-25 08:05:18.014405605 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.inline.hpp" #include "compiler/disassembler.hpp" #include "gc/shared/cardTableModRefBS.hpp" @@ -31,7 +32,6 @@ #include "memory/resourceArea.hpp" #include "memory/universe.hpp" #include "oops/klass.inline.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #include "runtime/biasedLocking.hpp" #include "runtime/interfaceSupport.hpp" --- old/src/hotspot/cpu/sparc/methodHandles_sparc.cpp 2017-10-25 08:05:27.091642969 -0400 +++ new/src/hotspot/cpu/sparc/methodHandles_sparc.cpp 2017-10-25 08:05:26.601546410 -0400 @@ -23,13 +23,13 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/javaClasses.inline.hpp" #include "interpreter/interpreter.hpp" #include "interpreter/interp_masm.hpp" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #define __ _masm-> --- old/src/hotspot/cpu/sparc/vm_version_sparc.cpp 2017-10-25 08:05:35.697226818 -0400 +++ new/src/hotspot/cpu/sparc/vm_version_sparc.cpp 2017-10-25 08:05:35.357888402 -0400 @@ -23,11 +23,11 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.inline.hpp" #include "logging/log.hpp" #include "logging/logStream.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/java.hpp" #include "runtime/os.hpp" #include "runtime/stubCodeGenerator.hpp" --- old/src/hotspot/cpu/x86/macroAssembler_x86.cpp 2017-10-25 08:05:44.300296451 -0400 +++ new/src/hotspot/cpu/x86/macroAssembler_x86.cpp 2017-10-25 08:05:43.816456307 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/assembler.hpp" #include "asm/assembler.inline.hpp" #include "compiler/disassembler.hpp" @@ -32,7 +33,6 @@ #include "memory/resourceArea.hpp" #include "memory/universe.hpp" #include "oops/klass.inline.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #include "runtime/biasedLocking.hpp" #include "runtime/interfaceSupport.hpp" --- old/src/hotspot/cpu/x86/methodHandles_x86.cpp 2017-10-25 08:05:52.966905719 -0400 +++ new/src/hotspot/cpu/x86/methodHandles_x86.cpp 2017-10-25 08:05:52.633548337 -0400 @@ -23,13 +23,13 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/javaClasses.inline.hpp" #include "interpreter/interpreter.hpp" #include "interpreter/interpreterRuntime.hpp" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #define __ _masm-> --- old/src/hotspot/cpu/x86/vm_version_x86.cpp 2017-10-25 08:06:01.473381619 -0400 +++ new/src/hotspot/cpu/x86/vm_version_x86.cpp 2017-10-25 08:06:00.905811424 -0400 @@ -23,12 +23,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "asm/macroAssembler.inline.hpp" #include "logging/log.hpp" #include "logging/logStream.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/java.hpp" #include "runtime/os.hpp" #include "runtime/stubCodeGenerator.hpp" --- old/src/hotspot/os/aix/jvm_aix.cpp 2017-10-25 08:06:10.669239138 -0400 +++ new/src/hotspot/os/aix/jvm_aix.cpp 2017-10-25 08:06:10.221284489 -0400 @@ -24,7 +24,7 @@ */ #include "precompiled.hpp" -#include "prims/jvm.h" +#include "jvm.h" #include "runtime/interfaceSupport.hpp" #include "runtime/osThread.hpp" --- old/src/hotspot/os/aix/os_aix.cpp 2017-10-25 08:06:19.097911365 -0400 +++ new/src/hotspot/os/aix/os_aix.cpp 2017-10-25 08:06:18.655964881 -0400 @@ -28,6 +28,7 @@ #pragma alloca // no precompiled headers +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -49,7 +50,6 @@ #include "os_share_aix.hpp" #include "porting_aix.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" @@ -3249,7 +3249,7 @@ } // ReduceSignalUsage allows the user to override these handlers - // see comments at the very top and jvm_solaris.h + // see comments at the very top and jvm_md.h if (!ReduceSignalUsage) { DO_SIGNAL_CHECK(SHUTDOWN1_SIGNAL); DO_SIGNAL_CHECK(SHUTDOWN2_SIGNAL); --- old/src/hotspot/os/bsd/decoder_machO.cpp 2017-10-25 08:06:27.645619661 -0400 +++ new/src/hotspot/os/bsd/decoder_machO.cpp 2017-10-25 08:06:27.235268202 -0400 @@ -25,7 +25,7 @@ #include "precompiled.hpp" #ifdef __APPLE__ -#include "prims/jvm.h" +#include "jvm.h" #include "decoder_machO.hpp" #include --- old/src/hotspot/os/bsd/jvm_bsd.cpp 2017-10-25 08:06:36.044315111 -0400 +++ new/src/hotspot/os/bsd/jvm_bsd.cpp 2017-10-25 08:06:35.712420702 -0400 @@ -23,7 +23,7 @@ */ #include "precompiled.hpp" -#include "prims/jvm.h" +#include "jvm.h" #include "runtime/interfaceSupport.hpp" #include "runtime/osThread.hpp" --- old/src/hotspot/os/bsd/os_bsd.cpp 2017-10-25 08:06:44.425067273 -0400 +++ new/src/hotspot/os/bsd/os_bsd.cpp 2017-10-25 08:06:44.090601564 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -31,7 +32,6 @@ #include "compiler/compileBroker.hpp" #include "compiler/disassembler.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_bsd.h" #include "logging/log.hpp" #include "memory/allocation.inline.hpp" #include "memory/filemap.hpp" @@ -39,7 +39,6 @@ #include "os_bsd.inline.hpp" #include "os_share_bsd.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" @@ -3240,7 +3239,7 @@ // ReduceSignalUsage allows the user to override these handlers - // see comments at the very top and jvm_solaris.h + // see comments at the very top and jvm_md.h if (!ReduceSignalUsage) { DO_SIGNAL_CHECK(SHUTDOWN1_SIGNAL); DO_SIGNAL_CHECK(SHUTDOWN2_SIGNAL); --- old/src/hotspot/os/linux/decoder_linux.cpp 2017-10-25 08:06:52.706966461 -0400 +++ new/src/hotspot/os/linux/decoder_linux.cpp 2017-10-25 08:06:52.295967243 -0400 @@ -22,7 +22,7 @@ * */ -#include "prims/jvm.h" +#include "jvm.h" #include "utilities/decoder_elf.hpp" #include --- old/src/hotspot/os/linux/jvm_linux.cpp 2017-10-25 08:07:00.931654297 -0400 +++ new/src/hotspot/os/linux/jvm_linux.cpp 2017-10-25 08:07:00.591366836 -0400 @@ -23,7 +23,7 @@ */ #include "precompiled.hpp" -#include "prims/jvm.h" +#include "jvm.h" #include "runtime/interfaceSupport.hpp" #include "runtime/osThread.hpp" --- old/src/hotspot/os/linux/os_linux.cpp 2017-10-25 08:07:09.238518874 -0400 +++ new/src/hotspot/os/linux/os_linux.cpp 2017-10-25 08:07:08.893839130 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -31,7 +32,6 @@ #include "compiler/compileBroker.hpp" #include "compiler/disassembler.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "logging/log.hpp" #include "memory/allocation.inline.hpp" #include "memory/filemap.hpp" @@ -39,7 +39,6 @@ #include "os_linux.inline.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" @@ -4664,7 +4663,7 @@ #endif // ReduceSignalUsage allows the user to override these handlers - // see comments at the very top and jvm_solaris.h + // see comments at the very top and jvm_md.h if (!ReduceSignalUsage) { DO_SIGNAL_CHECK(SHUTDOWN1_SIGNAL); DO_SIGNAL_CHECK(SHUTDOWN2_SIGNAL); --- old/src/hotspot/os/posix/os_posix.cpp 2017-10-25 08:07:17.823791306 -0400 +++ new/src/hotspot/os/posix/os_posix.cpp 2017-10-25 08:07:17.393066400 -0400 @@ -22,8 +22,8 @@ * */ +#include "jvm.h" #include "utilities/globalDefinitions.hpp" -#include "prims/jvm.h" #include "runtime/frame.inline.hpp" #include "runtime/interfaceSupport.hpp" #include "runtime/os.hpp" --- old/src/hotspot/os/solaris/jvm_solaris.cpp 2017-10-25 08:07:26.225031865 -0400 +++ new/src/hotspot/os/solaris/jvm_solaris.cpp 2017-10-25 08:07:25.776471817 -0400 @@ -23,7 +23,7 @@ */ #include "precompiled.hpp" -#include "prims/jvm.h" +#include "jvm.h" #include "runtime/interfaceSupport.hpp" #include "runtime/osThread.hpp" --- old/src/hotspot/os/solaris/os_solaris.cpp 2017-10-25 08:07:34.855418865 -0400 +++ new/src/hotspot/os/solaris/os_solaris.cpp 2017-10-25 08:07:34.456310100 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -31,7 +32,6 @@ #include "compiler/compileBroker.hpp" #include "compiler/disassembler.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_solaris.h" #include "logging/log.hpp" #include "memory/allocation.inline.hpp" #include "memory/filemap.hpp" @@ -39,7 +39,6 @@ #include "os_share_solaris.hpp" #include "os_solaris.inline.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" --- old/src/hotspot/os/windows/jvm_windows.cpp 2017-10-25 08:07:43.528907353 -0400 +++ new/src/hotspot/os/windows/jvm_windows.cpp 2017-10-25 08:07:43.109967761 -0400 @@ -23,7 +23,7 @@ */ #include "precompiled.hpp" -#include "prims/jvm.h" +#include "jvm.h" #include "runtime/interfaceSupport.hpp" #include "runtime/osThread.hpp" --- old/src/hotspot/os/windows/os_windows.cpp 2017-10-25 08:07:51.937881354 -0400 +++ new/src/hotspot/os/windows/os_windows.cpp 2017-10-25 08:07:51.537840673 -0400 @@ -26,6 +26,7 @@ #define _WIN32_WINNT 0x0600 // no precompiled headers +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -34,7 +35,6 @@ #include "compiler/compileBroker.hpp" #include "compiler/disassembler.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_windows.h" #include "logging/log.hpp" #include "memory/allocation.inline.hpp" #include "memory/filemap.hpp" @@ -42,7 +42,6 @@ #include "os_share_windows.hpp" #include "os_windows.inline.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" @@ -100,6 +99,7 @@ #include // For os::dll_address_to_function_name // for enumerating dll libraries #include +#include // for timer info max values which include all bits #define ALL_64_BITS CONST64(-1) @@ -3656,7 +3656,7 @@ static INIT_ONCE init_once_crit_sect = INIT_ONCE_STATIC_INIT; static CRITICAL_SECTION crit_sect; - static volatile jint process_exiting = 0; + static volatile int process_exiting = 0; int i, j; DWORD res; HANDLE hproc, hthr; @@ -3675,7 +3675,7 @@ if (what != EPT_THREAD) { // Atomically set process_exiting before the critical section // to increase the visibility between racing threads. - Atomic::cmpxchg((jint)GetCurrentThreadId(), &process_exiting, 0); + Atomic::cmpxchg((int)GetCurrentThreadId(), &process_exiting, 0); } EnterCriticalSection(&crit_sect); --- old/src/hotspot/os/windows/threadCritical_windows.cpp 2017-10-25 08:08:00.402585873 -0400 +++ new/src/hotspot/os/windows/threadCritical_windows.cpp 2017-10-25 08:08:00.080995179 -0400 @@ -36,7 +36,7 @@ // static bool initialized = false; -static volatile jint lock_count = -1; +static volatile int lock_count = -1; static HANDLE lock_event; static DWORD lock_owner = -1; --- old/src/hotspot/os_cpu/aix_ppc/os_aix_ppc.cpp 2017-10-25 08:08:09.291893631 -0400 +++ new/src/hotspot/os_cpu/aix_ppc/os_aix_ppc.cpp 2017-10-25 08:08:08.876451700 -0400 @@ -24,6 +24,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/assembler.inline.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -37,7 +38,6 @@ #include "nativeInst_ppc.hpp" #include "os_share_aix.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "porting_aix.hpp" #include "runtime/arguments.hpp" --- old/src/hotspot/os_cpu/bsd_x86/os_bsd_x86.cpp 2017-10-25 08:08:17.807687703 -0400 +++ new/src/hotspot/os_cpu/bsd_x86/os_bsd_x86.cpp 2017-10-25 08:08:17.363298455 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -31,11 +32,9 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_bsd.h" #include "memory/allocation.inline.hpp" #include "os_share_bsd.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/bsd_zero/os_bsd_zero.cpp 2017-10-25 08:08:26.271133830 -0400 +++ new/src/hotspot/os_cpu/bsd_zero/os_bsd_zero.cpp 2017-10-25 08:08:25.803995771 -0400 @@ -29,6 +29,7 @@ #endif // no precompiled headers +#include "jvm.h" #include "assembler_zero.inline.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -36,12 +37,10 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_bsd.h" #include "memory/allocation.inline.hpp" #include "nativeInst_zero.hpp" #include "os_share_bsd.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/linux_aarch64/os_linux_aarch64.cpp 2017-10-25 08:08:35.034046224 -0400 +++ new/src/hotspot/os_cpu/linux_aarch64/os_linux_aarch64.cpp 2017-10-25 08:08:34.542132300 -0400 @@ -24,6 +24,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -33,11 +34,9 @@ #include "code/vtableStubs.hpp" #include "code/nativeInst.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "memory/allocation.inline.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/linux_arm/os_linux_arm.cpp 2017-10-25 08:08:43.726591947 -0400 +++ new/src/hotspot/os_cpu/linux_arm/os_linux_arm.cpp 2017-10-25 08:08:43.231041173 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "assembler_arm.inline.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -30,12 +31,10 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "memory/allocation.inline.hpp" #include "nativeInst_arm.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/linux_ppc/os_linux_ppc.cpp 2017-10-25 08:08:52.093278770 -0400 +++ new/src/hotspot/os_cpu/linux_ppc/os_linux_ppc.cpp 2017-10-25 08:08:51.684533233 -0400 @@ -24,6 +24,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/assembler.inline.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -32,12 +33,10 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "memory/allocation.inline.hpp" #include "nativeInst_ppc.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/linux_s390/os_linux_s390.cpp 2017-10-25 08:09:00.518981283 -0400 +++ new/src/hotspot/os_cpu/linux_s390/os_linux_s390.cpp 2017-10-25 08:09:00.085762250 -0400 @@ -26,6 +26,7 @@ // This file is organized as os_linux_x86.cpp. // no precompiled headers +#include "jvm.h" #include "asm/assembler.inline.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -35,12 +36,10 @@ #include "code/vtableStubs.hpp" #include "compiler/disassembler.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "memory/allocation.inline.hpp" #include "nativeInst_s390.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/linux_sparc/os_linux_sparc.cpp 2017-10-25 08:09:09.057726765 -0400 +++ new/src/hotspot/os_cpu/linux_sparc/os_linux_sparc.cpp 2017-10-25 08:09:08.628456773 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -31,12 +32,10 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "memory/allocation.inline.hpp" #include "nativeInst_sparc.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp 2017-10-25 08:09:17.755256210 -0400 +++ new/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp 2017-10-25 08:09:17.266359618 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -31,11 +32,9 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "memory/allocation.inline.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/linux_zero/os_linux_zero.cpp 2017-10-25 08:09:26.244291825 -0400 +++ new/src/hotspot/os_cpu/linux_zero/os_linux_zero.cpp 2017-10-25 08:09:25.797563802 -0400 @@ -24,6 +24,7 @@ */ // no precompiled headers +#include "jvm.h" #include "assembler_zero.inline.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -31,12 +32,10 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_linux.h" #include "memory/allocation.inline.hpp" #include "nativeInst_zero.hpp" #include "os_share_linux.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/solaris_sparc/os_solaris_sparc.cpp 2017-10-25 08:09:35.050948076 -0400 +++ new/src/hotspot/os_cpu/solaris_sparc/os_solaris_sparc.cpp 2017-10-25 08:09:34.544538267 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "macroAssembler_sparc.hpp" #include "classfile/classLoader.hpp" @@ -32,12 +33,10 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_solaris.h" #include "memory/allocation.inline.hpp" #include "nativeInst_sparc.hpp" #include "os_share_solaris.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/os_cpu/solaris_x86/os_solaris_x86.cpp 2017-10-25 08:09:43.688339871 -0400 +++ new/src/hotspot/os_cpu/solaris_x86/os_solaris_x86.cpp 2017-10-25 08:09:43.266276676 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -31,11 +32,9 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_solaris.h" #include "memory/allocation.inline.hpp" #include "os_share_solaris.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" --- old/src/hotspot/os_cpu/windows_x86/os_windows_x86.cpp 2017-10-25 08:09:52.162766137 -0400 +++ new/src/hotspot/os_cpu/windows_x86/os_windows_x86.cpp 2017-10-25 08:09:51.742817639 -0400 @@ -23,6 +23,7 @@ */ // no precompiled headers +#include "jvm.h" #include "asm/macroAssembler.hpp" #include "classfile/classLoader.hpp" #include "classfile/systemDictionary.hpp" @@ -30,13 +31,11 @@ #include "code/icBuffer.hpp" #include "code/vtableStubs.hpp" #include "interpreter/interpreter.hpp" -#include "jvm_windows.h" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" #include "nativeInst_x86.hpp" #include "os_share_windows.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/extendedPC.hpp" --- old/src/hotspot/share/aot/aotLoader.cpp 2017-10-25 08:10:01.413419126 -0400 +++ new/src/hotspot/share/aot/aotLoader.cpp 2017-10-25 08:10:00.993078655 -0400 @@ -22,12 +22,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "aot/aotCodeHeap.hpp" #include "aot/aotLoader.inline.hpp" #include "jvmci/jvmciRuntime.hpp" #include "oops/method.hpp" -#include "prims/jvm.h" #include "runtime/os.hpp" #include "runtime/timerTrace.hpp" --- old/src/hotspot/share/c1/c1_CFGPrinter.cpp 2017-10-25 08:10:10.042998288 -0400 +++ new/src/hotspot/share/c1/c1_CFGPrinter.cpp 2017-10-25 08:10:09.617387212 -0400 @@ -23,13 +23,13 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "c1/c1_CFGPrinter.hpp" #include "c1/c1_IR.hpp" #include "c1/c1_InstructionPrinter.hpp" #include "c1/c1_LIR.hpp" #include "c1/c1_LinearScan.hpp" #include "c1/c1_ValueStack.hpp" -#include "prims/jvm.h" #ifndef PRODUCT --- old/src/hotspot/share/c1/c1_Canonicalizer.hpp 2017-10-25 08:10:18.259932186 -0400 +++ new/src/hotspot/share/c1/c1_Canonicalizer.hpp 2017-10-25 08:10:17.939976775 -0400 @@ -40,6 +40,10 @@ void set_constant(jlong x) { set_canonical(new Constant(new LongConstant(x))); } void set_constant(jfloat x) { set_canonical(new Constant(new FloatConstant(x))); } void set_constant(jdouble x) { set_canonical(new Constant(new DoubleConstant(x))); } +#ifdef _WINDOWS + // jint is defined as long in jni_md.h, so convert from int to jint + void set_constant(int x) { set_constant((jint)x); } +#endif void move_const_to_right(Op2* x); void do_Op2(Op2* x); void do_UnsafeRawOp(UnsafeRawOp* x); --- old/src/hotspot/share/c1/c1_LinearScan.cpp 2017-10-25 08:10:26.562577882 -0400 +++ new/src/hotspot/share/c1/c1_LinearScan.cpp 2017-10-25 08:10:26.186219931 -0400 @@ -2507,7 +2507,7 @@ // use). ConstantOopWriteValue* LinearScan::_oop_null_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantOopWriteValue(NULL); ConstantIntValue* LinearScan::_int_m1_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(-1); -ConstantIntValue* LinearScan::_int_0_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(0); +ConstantIntValue* LinearScan::_int_0_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue((jint)0); ConstantIntValue* LinearScan::_int_1_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(1); ConstantIntValue* LinearScan::_int_2_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(2); LocationValue* _illegal_value = new (ResourceObj::C_HEAP, mtCompiler) LocationValue(Location()); --- old/src/hotspot/share/ci/ciEnv.cpp 2017-10-25 08:10:35.819562720 -0400 +++ new/src/hotspot/share/ci/ciEnv.cpp 2017-10-25 08:10:35.367459168 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "ci/ciConstant.hpp" #include "ci/ciEnv.hpp" #include "ci/ciField.hpp" @@ -49,7 +50,6 @@ #include "oops/objArrayKlass.hpp" #include "oops/objArrayOop.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "runtime/init.hpp" #include "runtime/reflection.hpp" --- old/src/hotspot/share/ci/ciFlags.hpp 2017-10-25 08:10:44.227809913 -0400 +++ new/src/hotspot/share/ci/ciFlags.hpp 2017-10-25 08:10:43.897193821 -0400 @@ -25,9 +25,9 @@ #ifndef SHARE_VM_CI_CIFLAGS_HPP #define SHARE_VM_CI_CIFLAGS_HPP +#include "jvm.h" #include "ci/ciClassList.hpp" #include "memory/allocation.hpp" -#include "prims/jvm.h" #include "utilities/accessFlags.hpp" #include "utilities/ostream.hpp" --- old/src/hotspot/share/ci/ciReplay.cpp 2017-10-25 08:10:52.330999207 -0400 +++ new/src/hotspot/share/ci/ciReplay.cpp 2017-10-25 08:10:51.997341492 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "ci/ciMethodData.hpp" #include "ci/ciReplay.hpp" #include "ci/ciSymbol.hpp" @@ -33,7 +34,6 @@ #include "memory/oopFactory.hpp" #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "utilities/copy.hpp" #include "utilities/macros.hpp" @@ -790,7 +790,7 @@ while (field_signature[rank] == '[') { rank++; } - int* dims = NEW_RESOURCE_ARRAY(int, rank); + jint* dims = NEW_RESOURCE_ARRAY(jint, rank); dims[0] = length; for (int i = 1; i < rank; i++) { dims[i] = 1; // These aren't relevant to the compiler --- old/src/hotspot/share/classfile/altHashing.cpp 2017-10-25 08:11:00.687350788 -0400 +++ new/src/hotspot/share/classfile/altHashing.cpp 2017-10-25 08:11:00.248230830 -0400 @@ -42,15 +42,15 @@ juint AltHashing::compute_seed() { jlong nanos = os::javaTimeNanos(); jlong now = os::javaTimeMillis(); - int SEED_MATERIAL[8] = { - (int) object_hash(SystemDictionary::String_klass()), - (int) object_hash(SystemDictionary::System_klass()), - os::random(), // current thread isn't a java thread - (int) (((julong)nanos) >> 32), - (int) nanos, - (int) (((julong)now) >> 32), - (int) now, - (int) (os::javaTimeNanos() >> 2) + jint SEED_MATERIAL[8] = { + (jint) object_hash(SystemDictionary::String_klass()), + (jint) object_hash(SystemDictionary::System_klass()), + (jint) os::random(), // current thread isn't a java thread + (jint) (((julong)nanos) >> 32), + (jint) nanos, + (jint) (((julong)now) >> 32), + (jint) now, + (jint) (os::javaTimeNanos() >> 2) }; return murmur3_32(SEED_MATERIAL, 8); @@ -167,7 +167,7 @@ } // Hash used for the seed. -juint AltHashing::murmur3_32(juint seed, const int* data, int len) { +juint AltHashing::murmur3_32(juint seed, const jint* data, int len) { juint h1 = seed; int off = 0; @@ -202,6 +202,6 @@ return h1; } -juint AltHashing::murmur3_32(const int* data, int len) { +juint AltHashing::murmur3_32(const jint* data, int len) { return murmur3_32(0, data, len); } --- old/src/hotspot/share/classfile/altHashing.hpp 2017-10-25 08:11:09.152585677 -0400 +++ new/src/hotspot/share/classfile/altHashing.hpp 2017-10-25 08:11:08.781585207 -0400 @@ -43,8 +43,8 @@ static juint Integer_rotateLeft(juint i, int distance) { return (i << distance) | (i >> (32 - distance)); } - static juint murmur3_32(const int* data, int len); - static juint murmur3_32(juint seed, const int* data, int len); + static juint murmur3_32(const jint* data, int len); + static juint murmur3_32(juint seed, const jint* data, int len); public: static juint compute_seed(); --- old/src/hotspot/share/classfile/classFileParser.cpp 2017-10-25 08:11:17.721794198 -0400 +++ new/src/hotspot/share/classfile/classFileParser.cpp 2017-10-25 08:11:17.347464385 -0400 @@ -22,6 +22,7 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "aot/aotLoader.hpp" #include "classfile/classFileParser.hpp" #include "classfile/classFileStream.hpp" @@ -54,7 +55,6 @@ #include "oops/method.hpp" #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "prims/jvmtiThreadState.hpp" #include "runtime/javaCalls.hpp" --- old/src/hotspot/share/classfile/classLoader.cpp 2017-10-25 08:11:26.240663860 -0400 +++ new/src/hotspot/share/classfile/classLoader.cpp 2017-10-25 08:11:25.904053968 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classFileStream.hpp" #include "classfile/classLoader.hpp" #include "classfile/classLoaderData.inline.hpp" @@ -53,7 +54,6 @@ #include "oops/objArrayOop.inline.hpp" #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/arguments.hpp" #include "runtime/compilationPolicy.hpp" --- old/src/hotspot/share/classfile/compactHashtable.cpp 2017-10-25 08:11:35.170464022 -0400 +++ new/src/hotspot/share/classfile/compactHashtable.cpp 2017-10-25 08:11:34.759181305 -0400 @@ -23,12 +23,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/compactHashtable.inline.hpp" #include "classfile/javaClasses.hpp" #include "logging/logMessage.hpp" #include "memory/metadataFactory.hpp" #include "memory/metaspaceShared.hpp" -#include "prims/jvm.h" #include "runtime/vmThread.hpp" #include "utilities/numberSeq.hpp" #include --- old/src/hotspot/share/classfile/modules.cpp 2017-10-25 08:11:43.353098814 -0400 +++ new/src/hotspot/share/classfile/modules.cpp 2017-10-25 08:11:43.023989862 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classFileParser.hpp" #include "classfile/classLoader.hpp" #include "classfile/classLoaderData.inline.hpp" @@ -40,7 +41,6 @@ #include "logging/logStream.hpp" #include "memory/resourceArea.hpp" #include "oops/instanceKlass.hpp" -#include "prims/jvm.h" #include "runtime/arguments.hpp" #include "runtime/handles.inline.hpp" #include "runtime/javaCalls.hpp" --- old/src/hotspot/share/classfile/systemDictionary.cpp 2017-10-25 08:11:51.776474146 -0400 +++ new/src/hotspot/share/classfile/systemDictionary.cpp 2017-10-25 08:11:51.388282612 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "aot/aotLoader.hpp" #include "classfile/classFileParser.hpp" #include "classfile/classFileStream.hpp" @@ -61,7 +62,6 @@ #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" #include "oops/typeArrayKlass.hpp" -#include "prims/jvm.h" #include "prims/jvmtiEnvBase.hpp" #include "prims/resolvedMethodTable.hpp" #include "prims/methodHandles.hpp" --- old/src/hotspot/share/classfile/verifier.cpp 2017-10-25 08:12:00.285201122 -0400 +++ new/src/hotspot/share/classfile/verifier.cpp 2017-10-25 08:11:59.942388006 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classFileStream.hpp" #include "classfile/javaClasses.hpp" #include "classfile/stackMapTable.hpp" @@ -40,7 +41,6 @@ #include "oops/instanceKlass.hpp" #include "oops/oop.inline.hpp" #include "oops/typeArrayOop.hpp" -#include "prims/jvm.h" #include "runtime/fieldDescriptor.hpp" #include "runtime/handles.inline.hpp" #include "runtime/interfaceSupport.hpp" --- old/src/hotspot/share/classfile/vmSymbols.cpp 2017-10-25 08:12:08.699362718 -0400 +++ new/src/hotspot/share/classfile/vmSymbols.cpp 2017-10-25 08:12:08.349827902 -0400 @@ -23,12 +23,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/vmSymbols.hpp" #include "compiler/compilerDirectives.hpp" #include "memory/oopFactory.hpp" #include "memory/metaspaceClosure.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/handles.inline.hpp" #include "utilities/xmlstream.hpp" --- old/src/hotspot/share/code/codeBlob.cpp 2017-10-25 08:12:17.194816117 -0400 +++ new/src/hotspot/share/code/codeBlob.cpp 2017-10-25 08:12:16.768422943 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "code/codeBlob.hpp" #include "code/codeCache.hpp" #include "code/relocInfo.hpp" @@ -33,7 +34,6 @@ #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" #include "prims/forte.hpp" -#include "prims/jvm.h" #include "runtime/handles.inline.hpp" #include "runtime/interfaceSupport.hpp" #include "runtime/mutexLocker.hpp" --- old/src/hotspot/share/code/debugInfo.hpp 2017-10-25 08:12:25.427995589 -0400 +++ new/src/hotspot/share/code/debugInfo.hpp 2017-10-25 08:12:25.105754106 -0400 @@ -146,9 +146,9 @@ class ConstantIntValue: public ScopeValue { private: - jint _value; + int _value; public: - ConstantIntValue(jint value) { _value = value; } + ConstantIntValue(int value) { _value = value; } jint value() const { return _value; } bool is_constant_int() const { return true; } bool equals(ScopeValue* other) const { return false; } --- old/src/hotspot/share/code/nmethod.cpp 2017-10-25 08:12:34.057415641 -0400 +++ new/src/hotspot/share/code/nmethod.cpp 2017-10-25 08:12:33.683136290 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "code/codeCache.hpp" #include "code/compiledIC.hpp" #include "code/dependencies.hpp" @@ -41,7 +42,6 @@ #include "memory/resourceArea.hpp" #include "oops/methodData.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/jvmtiImpl.hpp" #include "runtime/atomic.hpp" #include "runtime/orderAccess.inline.hpp" --- old/src/hotspot/share/code/relocInfo.cpp 2017-10-25 08:12:42.524166155 -0400 +++ new/src/hotspot/share/code/relocInfo.cpp 2017-10-25 08:12:42.201639510 -0400 @@ -489,7 +489,7 @@ #ifndef _LP64 _target = (address) (intptr_t)unpack_1_int(); #else - int32_t lo, hi; + jint lo, hi; unpack_2_ints(lo, hi); jlong t = jlong_from(hi, lo);; _target = (address) t; --- old/src/hotspot/share/compiler/compileBroker.cpp 2017-10-25 08:12:51.295358870 -0400 +++ new/src/hotspot/share/compiler/compileBroker.cpp 2017-10-25 08:12:50.830532305 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/symbolTable.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -40,7 +41,6 @@ #include "oops/methodData.hpp" #include "oops/method.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/nativeLookup.hpp" #include "prims/whitebox.hpp" #include "runtime/arguments.hpp" @@ -108,7 +108,7 @@ bool CompileBroker::_initialized = false; volatile bool CompileBroker::_should_block = false; -volatile jint CompileBroker::_print_compilation_warning = 0; +volatile int CompileBroker::_print_compilation_warning = 0; volatile jint CompileBroker::_should_compile_new_jobs = run_compilation; // The installed compiler(s) --- old/src/hotspot/share/compiler/compileBroker.hpp 2017-10-25 08:12:59.804847391 -0400 +++ new/src/hotspot/share/compiler/compileBroker.hpp 2017-10-25 08:12:59.476972096 -0400 @@ -217,7 +217,7 @@ static int _sum_nmethod_code_size; static long _peak_compilation_time; - static volatile jint _print_compilation_warning; + static volatile int _print_compilation_warning; static JavaThread* make_thread(const char* name, CompileQueue* queue, CompilerCounters* counters, AbstractCompiler* comp, bool compiler_thread, TRAPS); static void init_compiler_sweeper_threads(int c1_compiler_count, int c2_compiler_count); --- old/src/hotspot/share/compiler/compileLog.cpp 2017-10-25 08:13:08.065507156 -0400 +++ new/src/hotspot/share/compiler/compileLog.cpp 2017-10-25 08:13:07.711090285 -0400 @@ -23,12 +23,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "ci/ciMethod.hpp" #include "code/codeCache.hpp" #include "compiler/compileLog.hpp" #include "memory/allocation.inline.hpp" #include "oops/method.hpp" -#include "prims/jvm.h" #include "runtime/mutexLocker.hpp" #include "runtime/os.hpp" --- old/src/hotspot/share/compiler/compilerOracle.cpp 2017-10-25 08:13:16.365956438 -0400 +++ new/src/hotspot/share/compiler/compilerOracle.cpp 2017-10-25 08:13:15.968574238 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "compiler/compilerOracle.hpp" #include "compiler/methodMatcher.hpp" #include "memory/allocation.inline.hpp" @@ -31,7 +32,6 @@ #include "oops/klass.hpp" #include "oops/method.hpp" #include "oops/symbol.hpp" -#include "prims/jvm.h" #include "runtime/handles.inline.hpp" #include "runtime/jniHandles.hpp" #include "runtime/os.hpp" --- old/src/hotspot/share/gc/g1/g1CollectedHeap.cpp 2017-10-25 08:13:25.706567951 -0400 +++ new/src/hotspot/share/gc/g1/g1CollectedHeap.cpp 2017-10-25 08:13:25.170056257 -0400 @@ -3622,7 +3622,7 @@ class G1KlassCleaningTask : public StackObj { BoolObjectClosure* _is_alive; - volatile jint _clean_klass_tree_claimed; + volatile int _clean_klass_tree_claimed; ClassLoaderDataGraphKlassIteratorAtomic _klass_iterator; public: @@ -3638,7 +3638,7 @@ return false; } - return Atomic::cmpxchg(1, (jint*)&_clean_klass_tree_claimed, 0) == 0; + return Atomic::cmpxchg(1, &_clean_klass_tree_claimed, 0) == 0; } InstanceKlass* claim_next_klass() { @@ -3675,7 +3675,7 @@ class G1ResolvedMethodCleaningTask : public StackObj { BoolObjectClosure* _is_alive; - volatile jint _resolved_method_task_claimed; + volatile int _resolved_method_task_claimed; public: G1ResolvedMethodCleaningTask(BoolObjectClosure* is_alive) : _is_alive(is_alive), _resolved_method_task_claimed(0) {} @@ -3684,7 +3684,7 @@ if (_resolved_method_task_claimed) { return false; } - return Atomic::cmpxchg(1, (jint*)&_resolved_method_task_claimed, 0) == 0; + return Atomic::cmpxchg(1, &_resolved_method_task_claimed, 0) == 0; } // These aren't big, one thread can do it all. --- old/src/hotspot/share/gc/g1/satbMarkQueue.cpp 2017-10-25 08:13:34.517353758 -0400 +++ new/src/hotspot/share/gc/g1/satbMarkQueue.cpp 2017-10-25 08:13:34.190724401 -0400 @@ -23,12 +23,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "gc/g1/g1CollectedHeap.inline.hpp" #include "gc/g1/satbMarkQueue.hpp" #include "gc/shared/collectedHeap.hpp" #include "memory/allocation.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/mutexLocker.hpp" #include "runtime/safepoint.hpp" #include "runtime/thread.hpp" --- old/src/hotspot/share/gc/shared/ageTable.cpp 2017-10-25 08:13:43.079396340 -0400 +++ new/src/hotspot/share/gc/shared/ageTable.cpp 2017-10-25 08:13:42.658394551 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "gc/shared/ageTable.inline.hpp" #include "gc/shared/ageTableTracer.hpp" #include "gc/shared/collectedHeap.hpp" @@ -30,7 +31,6 @@ #include "memory/resourceArea.hpp" #include "logging/log.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "utilities/copy.hpp" /* Copyright (c) 1992, 2016, Oracle and/or its affiliates, and Stanford University. --- old/src/hotspot/share/gc/shared/gcId.cpp 2017-10-25 08:13:51.518104172 -0400 +++ new/src/hotspot/share/gc/shared/gcId.cpp 2017-10-25 08:13:51.149893135 -0400 @@ -23,8 +23,8 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "gc/shared/gcId.hpp" -#include "prims/jvm.h" #include "runtime/safepoint.hpp" #include "runtime/thread.inline.hpp" --- old/src/hotspot/share/gc/shared/gcTimer.hpp 2017-10-25 08:13:59.951967787 -0400 +++ new/src/hotspot/share/gc/shared/gcTimer.hpp 2017-10-25 08:13:59.613714121 -0400 @@ -26,7 +26,6 @@ #define SHARE_VM_GC_SHARED_GCTIMER_HPP #include "memory/allocation.hpp" -#include "prims/jni_md.h" #include "utilities/macros.hpp" #include "utilities/ticks.hpp" --- old/src/hotspot/share/gc/shared/gcTraceTime.inline.hpp 2017-10-25 08:14:08.295461597 -0400 +++ new/src/hotspot/share/gc/shared/gcTraceTime.inline.hpp 2017-10-25 08:14:07.938950673 -0400 @@ -32,7 +32,6 @@ #include "logging/log.hpp" #include "logging/logStream.hpp" #include "memory/universe.hpp" -#include "prims/jni_md.h" #include "utilities/ticks.hpp" #define LOG_STOP_HEAP_FORMAT SIZE_FORMAT "M->" SIZE_FORMAT "M(" SIZE_FORMAT "M)" --- old/src/hotspot/share/interpreter/linkResolver.cpp 2017-10-25 08:14:17.110427064 -0400 +++ new/src/hotspot/share/interpreter/linkResolver.cpp 2017-10-25 08:14:16.598328587 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/defaultMethods.hpp" #include "classfile/javaClasses.hpp" #include "classfile/resolutionErrors.hpp" @@ -42,7 +43,6 @@ #include "oops/method.hpp" #include "oops/objArrayOop.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/methodHandles.hpp" #include "prims/nativeLookup.hpp" #include "runtime/compilationPolicy.hpp" --- old/src/hotspot/share/jvmci/jvmciCodeInstaller.cpp 2017-10-25 08:14:25.972624325 -0400 +++ new/src/hotspot/share/jvmci/jvmciCodeInstaller.cpp 2017-10-25 08:14:25.453165140 -0400 @@ -45,7 +45,7 @@ // use). ConstantOopWriteValue* CodeInstaller::_oop_null_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantOopWriteValue(NULL); ConstantIntValue* CodeInstaller::_int_m1_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(-1); -ConstantIntValue* CodeInstaller::_int_0_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(0); +ConstantIntValue* CodeInstaller::_int_0_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue((jint)0); ConstantIntValue* CodeInstaller::_int_1_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(1); ConstantIntValue* CodeInstaller::_int_2_scope_value = new (ResourceObj::C_HEAP, mtCompiler) ConstantIntValue(2); LocationValue* CodeInstaller::_illegal_value = new (ResourceObj::C_HEAP, mtCompiler) LocationValue(Location()); --- old/src/hotspot/share/jvmci/jvmciCompiler.cpp 2017-10-25 08:14:34.530787577 -0400 +++ new/src/hotspot/share/jvmci/jvmciCompiler.cpp 2017-10-25 08:14:34.204792438 -0400 @@ -22,10 +22,10 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "memory/oopFactory.hpp" #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/javaCalls.hpp" #include "runtime/handles.hpp" #include "jvmci/jvmciJavaClasses.hpp" --- old/src/hotspot/share/jvmci/jvmciCompilerToVM.cpp 2017-10-25 08:14:42.820690152 -0400 +++ new/src/hotspot/share/jvmci/jvmciCompilerToVM.cpp 2017-10-25 08:14:42.425311424 -0400 @@ -1697,7 +1697,7 @@ } while (length > 0) { jbyte* start = array->byte_at_addr(offset); - tty->write((char*) start, MIN2(length, O_BUFLEN)); + tty->write((char*) start, MIN2(length, (jint)O_BUFLEN)); length -= O_BUFLEN; offset += O_BUFLEN; } --- old/src/hotspot/share/jvmci/jvmciRuntime.cpp 2017-10-25 08:14:51.153986640 -0400 +++ new/src/hotspot/share/jvmci/jvmciRuntime.cpp 2017-10-25 08:14:50.819172489 -0400 @@ -22,6 +22,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "asm/codeBuffer.hpp" #include "classfile/javaClasses.inline.hpp" #include "code/codeCache.hpp" @@ -37,7 +38,6 @@ #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" #include "oops/objArrayOop.inline.hpp" -#include "prims/jvm.h" #include "runtime/biasedLocking.hpp" #include "runtime/interfaceSupport.hpp" #include "runtime/reflection.hpp" @@ -611,7 +611,7 @@ } JRT_END -JRT_ENTRY(jint, JVMCIRuntime::test_deoptimize_call_int(JavaThread* thread, int value)) +JRT_ENTRY(int, JVMCIRuntime::test_deoptimize_call_int(JavaThread* thread, int value)) deopt_caller(); return value; JRT_END --- old/src/hotspot/share/jvmci/jvmci_globals.cpp 2017-10-25 08:14:59.565263815 -0400 +++ new/src/hotspot/share/jvmci/jvmci_globals.cpp 2017-10-25 08:14:59.209675431 -0400 @@ -23,8 +23,8 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "jvmci/jvmci_globals.hpp" -#include "prims/jvm.h" #include "utilities/defaultStream.hpp" #include "runtime/globals_extension.hpp" --- old/src/hotspot/share/logging/logConfiguration.cpp 2017-10-25 08:15:07.958750801 -0400 +++ new/src/hotspot/share/logging/logConfiguration.cpp 2017-10-25 08:15:07.538058724 -0400 @@ -22,6 +22,7 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/log.hpp" #include "logging/logConfiguration.hpp" #include "logging/logDecorations.hpp" @@ -34,7 +35,6 @@ #include "logging/logTagSet.hpp" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/os.inline.hpp" #include "runtime/semaphore.hpp" #include "utilities/globalDefinitions.hpp" --- old/src/hotspot/share/logging/logDecorations.cpp 2017-10-25 08:15:16.323117396 -0400 +++ new/src/hotspot/share/logging/logDecorations.cpp 2017-10-25 08:15:15.980016715 -0400 @@ -22,9 +22,9 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/logConfiguration.hpp" #include "logging/logDecorations.hpp" -#include "prims/jvm.h" #include "runtime/os.inline.hpp" #include "runtime/thread.inline.hpp" #include "services/management.hpp" --- old/src/hotspot/share/logging/logFileOutput.cpp 2017-10-25 08:15:24.610316842 -0400 +++ new/src/hotspot/share/logging/logFileOutput.cpp 2017-10-25 08:15:24.220674994 -0400 @@ -22,11 +22,11 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/log.hpp" #include "logging/logConfiguration.hpp" #include "logging/logFileOutput.hpp" #include "memory/allocation.inline.hpp" -#include "prims/jvm.h" #include "runtime/arguments.hpp" #include "runtime/os.inline.hpp" #include "utilities/globalDefinitions.hpp" --- old/src/hotspot/share/logging/logFileStreamOutput.cpp 2017-10-25 08:15:32.912018878 -0400 +++ new/src/hotspot/share/logging/logFileStreamOutput.cpp 2017-10-25 08:15:32.592029069 -0400 @@ -22,12 +22,12 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/logDecorators.hpp" #include "logging/logDecorations.hpp" #include "logging/logFileStreamOutput.hpp" #include "logging/logMessageBuffer.hpp" #include "memory/allocation.inline.hpp" -#include "prims/jvm.h" static bool initialized; static union { --- old/src/hotspot/share/logging/logOutput.cpp 2017-10-25 08:15:41.321176017 -0400 +++ new/src/hotspot/share/logging/logOutput.cpp 2017-10-25 08:15:40.999576516 -0400 @@ -22,11 +22,11 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/logFileStreamOutput.hpp" #include "logging/logOutput.hpp" #include "logging/logTagSet.hpp" #include "memory/allocation.inline.hpp" -#include "prims/jvm.h" #include "runtime/mutexLocker.hpp" #include "runtime/os.inline.hpp" --- old/src/hotspot/share/logging/logTagSet.cpp 2017-10-25 08:15:49.362691787 -0400 +++ new/src/hotspot/share/logging/logTagSet.cpp 2017-10-25 08:15:49.042904007 -0400 @@ -22,6 +22,7 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/logDecorations.hpp" #include "logging/logFileStreamOutput.hpp" #include "logging/logLevel.hpp" @@ -31,7 +32,6 @@ #include "logging/logTagSet.hpp" #include "logging/logTagSetDescriptions.hpp" #include "memory/allocation.inline.hpp" -#include "prims/jvm.h" #include "utilities/ostream.hpp" LogTagSet* LogTagSet::_list = NULL; --- old/src/hotspot/share/memory/filemap.cpp 2017-10-25 08:15:57.794099052 -0400 +++ new/src/hotspot/share/memory/filemap.cpp 2017-10-25 08:15:57.281414849 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/compactHashtable.inline.hpp" #include "classfile/sharedClassUtil.hpp" @@ -42,7 +43,6 @@ #include "memory/metaspaceShared.hpp" #include "memory/oopFactory.hpp" #include "oops/objArrayOop.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "runtime/arguments.hpp" #include "runtime/java.hpp" --- old/src/hotspot/share/memory/metaspaceShared.cpp 2017-10-25 08:16:06.547572946 -0400 +++ new/src/hotspot/share/memory/metaspaceShared.cpp 2017-10-25 08:16:06.088826974 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classListParser.hpp" #include "classfile/classLoaderExt.hpp" #include "classfile/dictionary.hpp" @@ -55,7 +56,6 @@ #include "oops/objArrayOop.hpp" #include "oops/oop.inline.hpp" #include "oops/typeArrayKlass.hpp" -#include "prims/jvm.h" #include "prims/jvmtiRedefineClasses.hpp" #include "runtime/timerTrace.hpp" #include "runtime/os.hpp" --- old/src/hotspot/share/oops/constantPool.cpp 2017-10-25 08:16:15.410040518 -0400 +++ new/src/hotspot/share/oops/constantPool.cpp 2017-10-25 08:16:14.917907794 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classLoaderData.hpp" #include "classfile/javaClasses.inline.hpp" #include "classfile/metadataOnStackMark.hpp" @@ -41,7 +42,6 @@ #include "oops/objArrayKlass.hpp" #include "oops/objArrayOop.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/fieldType.hpp" #include "runtime/init.hpp" #include "runtime/javaCalls.hpp" --- old/src/hotspot/share/oops/generateOopMap.cpp 2017-10-25 08:16:23.675744991 -0400 +++ new/src/hotspot/share/oops/generateOopMap.cpp 2017-10-25 08:16:23.358796718 -0400 @@ -23,13 +23,13 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "interpreter/bytecodeStream.hpp" #include "logging/log.hpp" #include "logging/logStream.hpp" #include "oops/generateOopMap.hpp" #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" -#include "prims/jvm.h" #include "runtime/handles.inline.hpp" #include "runtime/java.hpp" #include "runtime/relocator.hpp" --- old/src/hotspot/share/oops/instanceKlass.cpp 2017-10-25 08:16:32.330291150 -0400 +++ new/src/hotspot/share/oops/instanceKlass.cpp 2017-10-25 08:16:31.939463871 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "aot/aotLoader.hpp" #include "classfile/classFileParser.hpp" #include "classfile/classFileStream.hpp" @@ -59,7 +60,6 @@ #include "oops/method.hpp" #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "prims/jvmtiRedefineClasses.hpp" #include "prims/jvmtiThreadState.hpp" --- old/src/hotspot/share/oops/klassVtable.cpp 2017-10-25 08:16:40.915605784 -0400 +++ new/src/hotspot/share/oops/klassVtable.cpp 2017-10-25 08:16:40.595306078 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" #include "gc/shared/gcLocker.hpp" @@ -36,7 +37,6 @@ #include "oops/method.hpp" #include "oops/objArrayOop.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/arguments.hpp" #include "runtime/handles.inline.hpp" #include "utilities/copy.hpp" --- old/src/hotspot/share/opto/castnode.cpp 2017-10-25 08:16:49.400781698 -0400 +++ new/src/hotspot/share/opto/castnode.cpp 2017-10-25 08:16:48.940531650 -0400 @@ -237,8 +237,8 @@ if (in_type != NULL && this_type != NULL && (in_type->_lo != this_type->_lo || in_type->_hi != this_type->_hi)) { - int lo1 = this_type->_lo; - int hi1 = this_type->_hi; + jint lo1 = this_type->_lo; + jint hi1 = this_type->_hi; int w1 = this_type->_widen; if (lo1 >= 0) { --- old/src/hotspot/share/opto/loopTransform.cpp 2017-10-25 08:16:57.652480475 -0400 +++ new/src/hotspot/share/opto/loopTransform.cpp 2017-10-25 08:16:57.279780840 -0400 @@ -2129,7 +2129,7 @@ // Look for trip_counter + offset vs limit Node *rc_exp = cmp->in(1); Node *limit = cmp->in(2); - jint scale_con= 1; // Assume trip counter not scaled + int scale_con= 1; // Assume trip counter not scaled Node *limit_c = get_ctrl(limit); if( loop->is_member(get_loop(limit_c) ) ) { --- old/src/hotspot/share/opto/mulnode.cpp 2017-10-25 08:17:06.074877500 -0400 +++ new/src/hotspot/share/opto/mulnode.cpp 2017-10-25 08:17:05.755713038 -0400 @@ -235,13 +235,13 @@ const TypeInt *r1 = t1->is_int(); // Fetch endpoints of all ranges - int32_t lo0 = r0->_lo; + jint lo0 = r0->_lo; double a = (double)lo0; - int32_t hi0 = r0->_hi; + jint hi0 = r0->_hi; double b = (double)hi0; - int32_t lo1 = r1->_lo; + jint lo1 = r1->_lo; double c = (double)lo1; - int32_t hi1 = r1->_hi; + jint hi1 = r1->_hi; double d = (double)hi1; // Compute all endpoints & check for overflow --- old/src/hotspot/share/opto/parse3.cpp 2017-10-25 08:17:14.374349875 -0400 +++ new/src/hotspot/share/opto/parse3.cpp 2017-10-25 08:17:14.026395775 -0400 @@ -412,9 +412,9 @@ // The original expression was of this form: new T[length0][length1]... // It is often the case that the lengths are small (except the last). // If that happens, use the fast 1-d creator a constant number of times. - const jint expand_limit = MIN2((jint)MultiArrayExpandLimit, 100); - jint expand_count = 1; // count of allocations in the expansion - jint expand_fanout = 1; // running total fanout + const int expand_limit = MIN2((int)MultiArrayExpandLimit, 100); + int expand_count = 1; // count of allocations in the expansion + int expand_fanout = 1; // running total fanout for (j = 0; j < ndimensions-1; j++) { jint dim_con = find_int_con(length[j], -1); expand_fanout *= dim_con; --- old/src/hotspot/share/opto/phaseX.cpp 2017-10-25 08:17:22.604163447 -0400 +++ new/src/hotspot/share/opto/phaseX.cpp 2017-10-25 08:17:22.276873145 -0400 @@ -723,7 +723,7 @@ //------------------------------intcon----------------------------------------- // Fast integer constant. Same as "transform(new ConINode(TypeInt::make(i)))" -ConINode* PhaseTransform::intcon(int i) { +ConINode* PhaseTransform::intcon(jint i) { // Small integer? Check cache! Check that cached node is not dead if (i >= _icon_min && i <= _icon_max) { ConINode* icon = _icons[i-_icon_min]; --- old/src/hotspot/share/precompiled/precompiled.hpp 2017-10-25 08:17:31.127408600 -0400 +++ new/src/hotspot/share/precompiled/precompiled.hpp 2017-10-25 08:17:30.649116903 -0400 @@ -27,6 +27,7 @@ #ifndef DONT_USE_PRECOMPILED_HEADER # include "jni.h" +# include "jvm.h" # include "asm/assembler.hpp" # include "asm/assembler.inline.hpp" # include "asm/codeBuffer.hpp" @@ -160,7 +161,6 @@ # include "oops/symbol.hpp" # include "oops/typeArrayKlass.hpp" # include "oops/typeArrayOop.hpp" -# include "prims/jvm.h" # include "prims/jvmtiExport.hpp" # include "prims/methodHandles.hpp" # include "runtime/arguments.hpp" --- old/src/hotspot/share/prims/jni.cpp 2017-10-25 08:17:40.055826691 -0400 +++ new/src/hotspot/share/prims/jni.cpp 2017-10-25 08:17:39.585656735 -0400 @@ -25,6 +25,7 @@ #include "precompiled.hpp" #include "jni.h" +#include "jvm.h" #include "ci/ciReplay.hpp" #include "classfile/altHashing.hpp" #include "classfile/classFileStream.hpp" @@ -55,7 +56,6 @@ #include "prims/jniCheck.hpp" #include "prims/jniExport.hpp" #include "prims/jniFastGetField.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "prims/jvmtiExport.hpp" #include "prims/jvmtiThreadState.hpp" @@ -263,7 +263,7 @@ #ifdef ASSERT Histogram* JNIHistogram; - static volatile jint JNIHistogram_lock = 0; + static volatile int JNIHistogram_lock = 0; class JNIHistogramElement : public HistogramElement { public: @@ -3277,9 +3277,9 @@ // Initialization state for three routines below relating to // java.nio.DirectBuffers -static jint directBufferSupportInitializeStarted = 0; -static volatile jint directBufferSupportInitializeEnded = 0; -static volatile jint directBufferSupportInitializeFailed = 0; +static int directBufferSupportInitializeStarted = 0; +static volatile int directBufferSupportInitializeEnded = 0; +static volatile int directBufferSupportInitializeFailed = 0; static jclass bufferClass = NULL; static jclass directBufferClass = NULL; static jclass directByteBufferClass = NULL; @@ -3844,9 +3844,9 @@ extern const struct JNIInvokeInterface_ jni_InvokeInterface; // Global invocation API vars -volatile jint vm_created = 0; +volatile int vm_created = 0; // Indicate whether it is safe to recreate VM -volatile jint safe_to_recreate_vm = 1; +volatile int safe_to_recreate_vm = 1; struct JavaVM_ main_vm = {&jni_InvokeInterface}; @@ -4045,7 +4045,7 @@ HOTSPOT_JNI_GETCREATEDJAVAVMS_ENTRY((void **) vm_buf, bufLen, (uintptr_t *) numVMs); - if (vm_created) { + if (vm_created == 1) { if (numVMs != NULL) *numVMs = 1; if (bufLen > 0) *vm_buf = (JavaVM *)(&main_vm); } else { @@ -4065,7 +4065,7 @@ jint res = JNI_ERR; DT_RETURN_MARK(DestroyJavaVM, jint, (const jint&)res); - if (!vm_created) { + if (vm_created == 0) { res = JNI_ERR; return res; } @@ -4086,7 +4086,7 @@ ThreadStateTransition::transition_from_native(thread, _thread_in_vm); if (Threads::destroy_vm()) { // Should not change thread state, VM is gone - vm_created = false; + vm_created = 0; res = JNI_OK; return res; } else { @@ -4226,7 +4226,7 @@ jint JNICALL jni_AttachCurrentThread(JavaVM *vm, void **penv, void *_args) { HOTSPOT_JNI_ATTACHCURRENTTHREAD_ENTRY(vm, penv, _args); - if (!vm_created) { + if (vm_created == 0) { HOTSPOT_JNI_ATTACHCURRENTTHREAD_RETURN((uint32_t) JNI_ERR); return JNI_ERR; } @@ -4285,7 +4285,7 @@ jint ret = JNI_ERR; DT_RETURN_MARK(GetEnv, jint, (const jint&)ret); - if (!vm_created) { + if (vm_created == 0) { *penv = NULL; ret = JNI_EDETACHED; return ret; @@ -4336,7 +4336,7 @@ jint JNICALL jni_AttachCurrentThreadAsDaemon(JavaVM *vm, void **penv, void *_args) { HOTSPOT_JNI_ATTACHCURRENTTHREADASDAEMON_ENTRY(vm, penv, _args); - if (!vm_created) { + if (vm_created == 0) { HOTSPOT_JNI_ATTACHCURRENTTHREADASDAEMON_RETURN((uint32_t) JNI_ERR); return JNI_ERR; } --- old/src/hotspot/share/prims/jniCheck.cpp 2017-10-25 08:17:48.582608301 -0400 +++ new/src/hotspot/share/prims/jniCheck.cpp 2017-10-25 08:17:48.246451502 -0400 @@ -24,6 +24,7 @@ #include "precompiled.hpp" #include "jni.h" +#include "jvm.h" #include "classfile/javaClasses.inline.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -32,7 +33,6 @@ #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" #include "prims/jniCheck.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "runtime/fieldDescriptor.hpp" #include "runtime/handles.hpp" --- old/src/hotspot/share/prims/jvm.cpp 2017-10-25 08:17:56.956300115 -0400 +++ new/src/hotspot/share/prims/jvm.cpp 2017-10-25 08:17:56.541261129 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classFileStream.hpp" #include "classfile/classLoader.hpp" #include "classfile/classLoaderData.inline.hpp" @@ -46,7 +47,6 @@ #include "oops/objArrayKlass.hpp" #include "oops/objArrayOop.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "prims/jvmtiExport.hpp" #include "prims/jvmtiThreadState.hpp" @@ -215,7 +215,7 @@ #ifdef ASSERT Histogram* JVMHistogram; - volatile jint JVMHistogram_lock = 0; + volatile int JVMHistogram_lock = 0; class JVMHistogramElement : public HistogramElement { public: @@ -3766,7 +3766,7 @@ // when we add a new capability in the jvm_version_info struct, we should also // consider to expose this new capability in the sun.rt.jvmCapabilities jvmstat // counter defined in runtimeService.cpp. - info->is_attachable = AttachListener::is_attach_supported(); + info->is_attach_supported = AttachListener::is_attach_supported(); } JVM_END --- old/src/hotspot/share/prims/jvmtiEnvBase.cpp 2017-10-25 08:18:05.667655722 -0400 +++ new/src/hotspot/share/prims/jvmtiEnvBase.cpp 2017-10-25 08:18:05.315439657 -0400 @@ -741,7 +741,7 @@ // Save JNI local handles for any objects that this frame owns. jvmtiError JvmtiEnvBase::get_locked_objects_in_frame(JavaThread* calling_thread, JavaThread* java_thread, - javaVFrame *jvf, GrowableArray* owned_monitors_list, int stack_depth) { + javaVFrame *jvf, GrowableArray* owned_monitors_list, jint stack_depth) { jvmtiError err = JVMTI_ERROR_NONE; ResourceMark rm; --- old/src/hotspot/share/prims/jvmtiImpl.cpp 2017-10-25 08:18:13.987282091 -0400 +++ new/src/hotspot/share/prims/jvmtiImpl.cpp 2017-10-25 08:18:13.610127595 -0400 @@ -523,7 +523,7 @@ // // Constructor for non-object getter -VM_GetOrSetLocal::VM_GetOrSetLocal(JavaThread* thread, jint depth, int index, BasicType type) +VM_GetOrSetLocal::VM_GetOrSetLocal(JavaThread* thread, jint depth, jint index, BasicType type) : _thread(thread) , _calling_thread(NULL) , _depth(depth) @@ -536,7 +536,7 @@ } // Constructor for object or non-object setter -VM_GetOrSetLocal::VM_GetOrSetLocal(JavaThread* thread, jint depth, int index, BasicType type, jvalue value) +VM_GetOrSetLocal::VM_GetOrSetLocal(JavaThread* thread, jint depth, jint index, BasicType type, jvalue value) : _thread(thread) , _calling_thread(NULL) , _depth(depth) --- old/src/hotspot/share/prims/jvmtiTagMap.cpp 2017-10-25 08:18:22.271049140 -0400 +++ new/src/hotspot/share/prims/jvmtiTagMap.cpp 2017-10-25 08:18:21.863634524 -0400 @@ -2006,7 +2006,7 @@ jlong thread_tag, jint depth, jmethodID method, - jint slot, + int slot, oop obj) { assert(ServiceUtil::visible_oop(obj), "checking"); --- old/src/hotspot/share/prims/methodHandles.hpp 2017-10-25 08:18:30.693585211 -0400 +++ new/src/hotspot/share/prims/methodHandles.hpp 2017-10-25 08:18:30.332202357 -0400 @@ -27,7 +27,6 @@ #include "classfile/javaClasses.hpp" #include "classfile/vmSymbols.hpp" -#include "prims/jvm.h" #include "runtime/frame.inline.hpp" #include "runtime/globals.hpp" #include "runtime/interfaceSupport.hpp" --- old/src/hotspot/share/prims/perf.cpp 2017-10-25 08:18:39.042561824 -0400 +++ new/src/hotspot/share/prims/perf.cpp 2017-10-25 08:18:38.657072037 -0400 @@ -24,11 +24,11 @@ #include "precompiled.hpp" #include "jni.h" +#include "jvm.h" #include "classfile/vmSymbols.hpp" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/interfaceSupport.hpp" #include "runtime/perfData.hpp" #include "runtime/perfMemory.hpp" --- old/src/hotspot/share/prims/unsafe.cpp 2017-10-25 08:18:47.382449442 -0400 +++ new/src/hotspot/share/prims/unsafe.cpp 2017-10-25 08:18:46.988500749 -0400 @@ -24,6 +24,7 @@ #include "precompiled.hpp" #include "jni.h" +#include "jvm.h" #include "classfile/classFileStream.hpp" #include "classfile/vmSymbols.hpp" #include "memory/allocation.inline.hpp" @@ -31,7 +32,6 @@ #include "oops/fieldStreams.hpp" #include "oops/objArrayOop.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/unsafe.hpp" #include "runtime/atomic.hpp" #include "runtime/globals.hpp" --- old/src/hotspot/share/runtime/arguments.cpp 2017-10-25 08:18:55.977183637 -0400 +++ new/src/hotspot/share/runtime/arguments.cpp 2017-10-25 08:18:55.448843203 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/javaAssertions.hpp" #include "classfile/moduleEntry.hpp" @@ -39,7 +40,6 @@ #include "memory/allocation.inline.hpp" #include "memory/universe.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "runtime/arguments.hpp" #include "runtime/arguments_ext.hpp" --- old/src/hotspot/share/runtime/commandLineFlagRangeList.cpp 2017-10-25 08:19:04.467954493 -0400 +++ new/src/hotspot/share/runtime/commandLineFlagRangeList.cpp 2017-10-25 08:19:04.128264731 -0400 @@ -23,10 +23,10 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/stringTable.hpp" #include "classfile/symbolTable.hpp" #include "gc/shared/referenceProcessor.hpp" -#include "prims/jvm.h" #include "oops/markOop.hpp" #include "runtime/arguments.hpp" #include "runtime/commandLineFlagConstraintList.hpp" --- old/src/hotspot/share/runtime/deoptimization.cpp 2017-10-25 08:19:12.719461166 -0400 +++ new/src/hotspot/share/runtime/deoptimization.cpp 2017-10-25 08:19:12.391441367 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/systemDictionary.hpp" #include "code/codeCache.hpp" #include "code/debugInfoRec.hpp" @@ -40,7 +41,6 @@ #include "oops/oop.inline.hpp" #include "oops/fieldStreams.hpp" #include "oops/verifyOopClosure.hpp" -#include "prims/jvm.h" #include "prims/jvmtiThreadState.hpp" #include "runtime/biasedLocking.hpp" #include "runtime/compilationPolicy.hpp" --- old/src/hotspot/share/runtime/globals.cpp 2017-10-25 08:19:21.410802540 -0400 +++ new/src/hotspot/share/runtime/globals.cpp 2017-10-25 08:19:21.068118017 -0400 @@ -23,9 +23,9 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "memory/allocation.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/arguments.hpp" #include "runtime/globals.hpp" #include "runtime/globals_extension.hpp" --- old/src/hotspot/share/runtime/interfaceSupport.cpp 2017-10-25 08:19:30.197794717 -0400 +++ new/src/hotspot/share/runtime/interfaceSupport.cpp 2017-10-25 08:19:29.853587087 -0400 @@ -47,7 +47,7 @@ Histogram* RuntimeHistogram; RuntimeHistogramElement::RuntimeHistogramElement(const char* elementName) { - static volatile jint RuntimeHistogram_lock = 0; + static volatile int RuntimeHistogram_lock = 0; _name = elementName; uintx count = 0; --- old/src/hotspot/share/runtime/java.cpp 2017-10-25 08:19:38.443559475 -0400 +++ new/src/hotspot/share/runtime/java.cpp 2017-10-25 08:19:38.065482304 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "aot/aotLoader.hpp" #include "classfile/classLoader.hpp" #include "classfile/stringTable.hpp" @@ -49,7 +50,6 @@ #include "oops/objArrayOop.hpp" #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "runtime/arguments.hpp" #include "runtime/biasedLocking.hpp" --- old/src/hotspot/share/runtime/os.cpp 2017-10-25 08:19:46.767185546 -0400 +++ new/src/hotspot/share/runtime/os.cpp 2017-10-25 08:19:46.392398316 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/javaClasses.hpp" #include "classfile/moduleEntry.hpp" @@ -41,7 +42,6 @@ #endif #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "prims/privilegedStack.hpp" #include "runtime/arguments.hpp" --- old/src/hotspot/share/runtime/os.hpp 2017-10-25 08:19:54.919238752 -0400 +++ new/src/hotspot/share/runtime/os.hpp 2017-10-25 08:19:54.580321406 -0400 @@ -25,8 +25,8 @@ #ifndef SHARE_VM_RUNTIME_OS_HPP #define SHARE_VM_RUNTIME_OS_HPP +#include "jvm.h" #include "jvmtifiles/jvmti.h" -#include "prims/jvm.h" #include "runtime/extendedPC.hpp" #include "runtime/handles.hpp" #include "utilities/macros.hpp" --- old/src/hotspot/share/runtime/perfData.cpp 2017-10-25 08:20:03.220960337 -0400 +++ new/src/hotspot/share/runtime/perfData.cpp 2017-10-25 08:20:02.888725627 -0400 @@ -23,10 +23,10 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/vmSymbols.hpp" #include "logging/log.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/handles.inline.hpp" #include "runtime/java.hpp" #include "runtime/mutex.hpp" @@ -420,11 +420,11 @@ PerfStringVariable* PerfDataManager::create_string_variable(CounterNS ns, const char* name, - jint max_length, + int max_length, const char* s, TRAPS) { - if (max_length == 0 && s != NULL) max_length = (jint)strlen(s); + if (max_length == 0 && s != NULL) max_length = (int)strlen(s); assert(max_length != 0, "PerfStringVariable with length 0"); --- old/src/hotspot/share/runtime/perfMemory.cpp 2017-10-25 08:20:11.512602629 -0400 +++ new/src/hotspot/share/runtime/perfMemory.cpp 2017-10-25 08:20:11.164189114 -0400 @@ -23,9 +23,9 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/log.hpp" #include "memory/allocation.inline.hpp" -#include "prims/jvm.h" #include "runtime/arguments.hpp" #include "runtime/java.hpp" #include "runtime/mutex.hpp" @@ -51,7 +51,7 @@ char* PerfMemory::_end = NULL; char* PerfMemory::_top = NULL; size_t PerfMemory::_capacity = 0; -jint PerfMemory::_initialized = false; +int PerfMemory::_initialized = false; PerfDataPrologue* PerfMemory::_prologue = NULL; bool PerfMemory::_destroyed = false; --- old/src/hotspot/share/runtime/perfMemory.hpp 2017-10-25 08:20:19.981625100 -0400 +++ new/src/hotspot/share/runtime/perfMemory.hpp 2017-10-25 08:20:19.653593522 -0400 @@ -120,7 +120,7 @@ static char* _top; static size_t _capacity; static PerfDataPrologue* _prologue; - static jint _initialized; + static int _initialized; static bool _destroyed; static void create_memory_region(size_t sizep); --- old/src/hotspot/share/runtime/reflection.cpp 2017-10-25 08:20:28.528801829 -0400 +++ new/src/hotspot/share/runtime/reflection.cpp 2017-10-25 08:20:28.097905584 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/javaClasses.hpp" #include "classfile/moduleEntry.hpp" #include "classfile/packageEntry.hpp" @@ -38,7 +39,6 @@ #include "oops/objArrayKlass.hpp" #include "oops/objArrayOop.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "runtime/arguments.hpp" #include "runtime/handles.inline.hpp" --- old/src/hotspot/share/runtime/sharedRuntime.cpp 2017-10-25 08:20:37.198166381 -0400 +++ new/src/hotspot/share/runtime/sharedRuntime.cpp 2017-10-25 08:20:36.798339002 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "aot/aotLoader.hpp" #include "classfile/stringTable.hpp" #include "classfile/systemDictionary.hpp" @@ -45,7 +46,6 @@ #include "oops/objArrayKlass.hpp" #include "oops/oop.inline.hpp" #include "prims/forte.hpp" -#include "prims/jvm.h" #include "prims/jvmtiExport.hpp" #include "prims/methodHandles.hpp" #include "prims/nativeLookup.hpp" --- old/src/hotspot/share/runtime/thread.cpp 2017-10-25 08:20:45.813086833 -0400 +++ new/src/hotspot/share/runtime/thread.cpp 2017-10-25 08:20:45.425947839 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classLoader.hpp" #include "classfile/javaClasses.hpp" #include "classfile/moduleEntry.hpp" @@ -51,7 +52,6 @@ #include "oops/oop.inline.hpp" #include "oops/symbol.hpp" #include "oops/verifyOopClosure.hpp" -#include "prims/jvm.h" #include "prims/jvm_misc.hpp" #include "prims/jvmtiExport.hpp" #include "prims/jvmtiThreadState.hpp" @@ -762,7 +762,7 @@ // GC Support bool Thread::claim_oops_do_par_case(int strong_roots_parity) { - jint thread_parity = _oops_do_parity; + int thread_parity = _oops_do_parity; if (thread_parity != strong_roots_parity) { jint res = Atomic::cmpxchg(strong_roots_parity, &_oops_do_parity, thread_parity); if (res == thread_parity) { --- old/src/hotspot/share/runtime/thread.hpp 2017-10-25 08:20:54.233059124 -0400 +++ new/src/hotspot/share/runtime/thread.hpp 2017-10-25 08:20:53.897570565 -0400 @@ -244,7 +244,7 @@ // The parity of the last strong_roots iteration in which this thread was // claimed as a task. - jint _oops_do_parity; + int _oops_do_parity; public: void set_last_handle_mark(HandleMark* mark) { _last_handle_mark = mark; } --- old/src/hotspot/share/runtime/vmStructs.cpp 2017-10-25 08:21:02.786166184 -0400 +++ new/src/hotspot/share/runtime/vmStructs.cpp 2017-10-25 08:21:02.414009386 -0400 @@ -356,7 +356,7 @@ nonstatic_field(Symbol, _length, unsigned short) \ unchecked_nonstatic_field(Symbol, _body, sizeof(jbyte)) /* NOTE: no type */ \ nonstatic_field(Symbol, _body[0], jbyte) \ - nonstatic_field(TypeArrayKlass, _max_length, int) \ + nonstatic_field(TypeArrayKlass, _max_length, jint) \ \ /***********************/ \ /* Constant Pool Cache */ \ @@ -579,7 +579,7 @@ static_field(PerfMemory, _top, char*) \ static_field(PerfMemory, _capacity, size_t) \ static_field(PerfMemory, _prologue, PerfDataPrologue*) \ - static_field(PerfMemory, _initialized, jint) \ + static_field(PerfMemory, _initialized, int) \ \ /***************/ \ /* SymbolTable */ \ --- old/src/hotspot/share/services/diagnosticArgument.cpp 2017-10-25 08:21:11.561834699 -0400 +++ new/src/hotspot/share/services/diagnosticArgument.cpp 2017-10-25 08:21:11.097754561 -0400 @@ -23,9 +23,9 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "memory/allocation.inline.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/thread.hpp" #include "services/diagnosticArgument.hpp" --- old/src/hotspot/share/services/diagnosticCommand.cpp 2017-10-25 08:21:19.927158512 -0400 +++ new/src/hotspot/share/services/diagnosticCommand.cpp 2017-10-25 08:21:19.604056323 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/classLoaderStats.hpp" #include "classfile/compactHashtable.hpp" #include "compiler/compileBroker.hpp" @@ -30,7 +31,6 @@ #include "gc/shared/vmGCOperations.hpp" #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/globals.hpp" #include "runtime/javaCalls.hpp" #include "runtime/os.hpp" --- old/src/hotspot/share/services/diagnosticFramework.cpp 2017-10-25 08:21:28.003016700 -0400 +++ new/src/hotspot/share/services/diagnosticFramework.cpp 2017-10-25 08:21:27.678325068 -0400 @@ -23,10 +23,10 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "memory/oopFactory.hpp" #include "memory/resourceArea.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/javaCalls.hpp" #include "runtime/mutexLocker.hpp" #include "services/diagnosticArgument.hpp" --- old/src/hotspot/share/services/heapDumper.cpp 2017-10-25 08:21:36.304651510 -0400 +++ new/src/hotspot/share/services/heapDumper.cpp 2017-10-25 08:21:35.982185868 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/symbolTable.hpp" #include "classfile/systemDictionary.hpp" #include "classfile/vmSymbols.hpp" @@ -34,7 +35,6 @@ #include "oops/objArrayKlass.hpp" #include "oops/objArrayOop.inline.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/javaCalls.hpp" #include "runtime/jniHandles.hpp" #include "runtime/os.hpp" --- old/src/hotspot/share/services/mallocSiteTable.cpp 2017-10-25 08:21:44.945424989 -0400 +++ new/src/hotspot/share/services/mallocSiteTable.cpp 2017-10-25 08:21:44.605004396 -0400 @@ -235,8 +235,8 @@ void MallocSiteTable::AccessLock::exclusiveLock() { - jint target; - jint val; + int target; + int val; assert(_lock_state != ExclusiveLock, "Can only call once"); assert(*_lock >= 0, "Can not content exclusive lock"); --- old/src/hotspot/share/services/memTracker.cpp 2017-10-25 08:21:53.045665645 -0400 +++ new/src/hotspot/share/services/memTracker.cpp 2017-10-25 08:21:52.707386254 -0400 @@ -22,8 +22,8 @@ * */ #include "precompiled.hpp" +#include "jvm.h" -#include "prims/jvm.h" #include "runtime/mutex.hpp" #include "services/memBaseline.hpp" #include "services/memReporter.hpp" --- old/src/hotspot/share/utilities/accessFlags.hpp 2017-10-25 08:22:01.398968870 -0400 +++ new/src/hotspot/share/utilities/accessFlags.hpp 2017-10-25 08:22:00.969284647 -0400 @@ -25,8 +25,8 @@ #ifndef SHARE_VM_UTILITIES_ACCESSFLAGS_HPP #define SHARE_VM_UTILITIES_ACCESSFLAGS_HPP +#include "jvm.h" #include "memory/allocation.hpp" -#include "prims/jvm.h" #include "utilities/macros.hpp" // AccessFlags is an abstraction over Java access flags. --- old/src/hotspot/share/utilities/constantTag.hpp 2017-10-25 08:22:09.668100428 -0400 +++ new/src/hotspot/share/utilities/constantTag.hpp 2017-10-25 08:22:09.332101870 -0400 @@ -25,8 +25,8 @@ #ifndef SHARE_VM_UTILITIES_CONSTANTTAG_HPP #define SHARE_VM_UTILITIES_CONSTANTTAG_HPP +#include "jvm.h" #include "memory/allocation.hpp" -#include "prims/jvm.h" // constant tags in Java .class files --- old/src/hotspot/share/utilities/debug.cpp 2017-10-25 08:22:18.042291781 -0400 +++ new/src/hotspot/share/utilities/debug.cpp 2017-10-25 08:22:17.697467554 -0400 @@ -23,6 +23,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "classfile/systemDictionary.hpp" #include "code/codeCache.hpp" #include "code/icBuffer.hpp" @@ -36,7 +37,6 @@ #include "memory/resourceArea.hpp" #include "memory/universe.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "prims/privilegedStack.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" @@ -276,7 +276,7 @@ } void report_java_out_of_memory(const char* message) { - static jint out_of_memory_reported = 0; + static int out_of_memory_reported = 0; // A number of threads may attempt to report OutOfMemoryError at around the // same time. To avoid dumping the heap or executing the data collection --- old/src/hotspot/share/utilities/decoder.cpp 2017-10-25 08:22:26.258853772 -0400 +++ new/src/hotspot/share/utilities/decoder.cpp 2017-10-25 08:22:25.917196927 -0400 @@ -23,7 +23,7 @@ */ #include "precompiled.hpp" -#include "prims/jvm.h" +#include "jvm.h" #include "runtime/os.hpp" #include "utilities/decoder.hpp" #include "utilities/vmError.hpp" --- old/src/hotspot/share/utilities/elfStringTable.cpp 2017-10-25 08:22:34.796632168 -0400 +++ new/src/hotspot/share/utilities/elfStringTable.cpp 2017-10-25 08:22:34.475917834 -0400 @@ -26,8 +26,8 @@ #if !defined(_WINDOWS) && !defined(__APPLE__) +#include "jvm.h" #include "memory/allocation.inline.hpp" -#include "prims/jvm.h" #include "runtime/os.hpp" #include "utilities/elfStringTable.hpp" --- old/src/hotspot/share/utilities/formatBuffer.cpp 2017-10-25 08:22:43.142063854 -0400 +++ new/src/hotspot/share/utilities/formatBuffer.cpp 2017-10-25 08:22:42.717683833 -0400 @@ -23,8 +23,8 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "memory/allocation.hpp" -#include "prims/jvm.h" #include "utilities/formatBuffer.hpp" #include --- old/src/hotspot/share/utilities/formatBuffer.hpp 2017-10-25 08:22:51.281790060 -0400 +++ new/src/hotspot/share/utilities/formatBuffer.hpp 2017-10-25 08:22:50.937747368 -0400 @@ -25,8 +25,8 @@ #ifndef SHARE_VM_UTILITIES_FORMATBUFFER_HPP #define SHARE_VM_UTILITIES_FORMATBUFFER_HPP +#include "jvm.h" #include "utilities/globalDefinitions.hpp" -#include "prims/jvm.h" #include // Simple class to format the ctor arguments into a fixed-sized buffer. --- old/src/hotspot/share/utilities/globalDefinitions.hpp 2017-10-25 08:22:59.572786338 -0400 +++ new/src/hotspot/share/utilities/globalDefinitions.hpp 2017-10-25 08:22:59.203099693 -0400 @@ -1258,6 +1258,14 @@ #undef JAVA_INTEGER_OP +#ifdef _WINDOWS +// Overloading to match (int, int) to (jint, jint) +// because windows jint is type long +inline jint java_add(int in1, int in2) { + return java_add((jint)in1, (jint)in2); +} +#endif + // Dereference vptr // All C++ compilers that we know of have the vtbl pointer in the first // word. If there are exceptions, this function needs to be made compiler --- old/src/hotspot/share/utilities/macros.hpp 2017-10-25 08:23:08.113653548 -0400 +++ new/src/hotspot/share/utilities/macros.hpp 2017-10-25 08:23:07.771927538 -0400 @@ -322,7 +322,9 @@ #endif #if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__APPLE__) +#ifndef BSD #define BSD +#endif // BSD defined in #define BSD_ONLY(code) code #define NOT_BSD(code) #else --- old/src/hotspot/share/utilities/ostream.cpp 2017-10-25 08:23:16.700246046 -0400 +++ new/src/hotspot/share/utilities/ostream.cpp 2017-10-25 08:23:16.334404911 -0400 @@ -23,9 +23,9 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "compiler/compileLog.hpp" #include "oops/oop.inline.hpp" -#include "prims/jvm.h" #include "runtime/arguments.hpp" #include "runtime/os.hpp" #include "runtime/vm_version.hpp" --- old/src/hotspot/share/utilities/vmError.cpp 2017-10-25 08:23:25.112392012 -0400 +++ new/src/hotspot/share/utilities/vmError.cpp 2017-10-25 08:23:24.729093368 -0400 @@ -23,12 +23,12 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "code/codeCache.hpp" #include "compiler/compileBroker.hpp" #include "compiler/disassembler.hpp" #include "gc/shared/collectedHeap.hpp" #include "logging/logConfiguration.hpp" -#include "prims/jvm.h" #include "prims/whitebox.hpp" #include "runtime/arguments.hpp" #include "runtime/atomic.hpp" --- old/src/java.base/share/native/include/classfile_constants.h 2017-10-25 08:23:35.425288109 -0400 +++ new/src/java.base/share/native/include/classfile_constants.h 2017-10-25 08:23:35.013985880 -0400 @@ -54,9 +54,29 @@ JVM_ACC_STRICT = 0x0800, JVM_ACC_SYNTHETIC = 0x1000, JVM_ACC_ANNOTATION = 0x2000, - JVM_ACC_ENUM = 0x4000 + JVM_ACC_ENUM = 0x4000, + JVM_ACC_MODULE = 0x8000 }; +#define JVM_ACC_PUBLIC_BIT 0 +#define JVM_ACC_PRIVATE_BIT 1 +#define JVM_ACC_PROTECTED_BIT 2 +#define JVM_ACC_STATIC_BIT 3 +#define JVM_ACC_FINAL_BIT 4 +#define JVM_ACC_SYNCHRONIZED_BIT 5 +#define JVM_ACC_SUPER_BIT 5 +#define JVM_ACC_VOLATILE_BIT 6 +#define JVM_ACC_BRIDGE_BIT 6 +#define JVM_ACC_TRANSIENT_BIT 7 +#define JVM_ACC_VARARGS_BIT 7 +#define JVM_ACC_NATIVE_BIT 8 +#define JVM_ACC_INTERFACE_BIT 9 +#define JVM_ACC_ABSTRACT_BIT 10 +#define JVM_ACC_STRICT_BIT 11 +#define JVM_ACC_SYNTHETIC_BIT 12 +#define JVM_ACC_ANNOTATION_BIT 13 +#define JVM_ACC_ENUM_BIT 14 + /* Used in newarray instruction. */ enum { @@ -86,8 +106,9 @@ JVM_CONSTANT_InterfaceMethodref = 11, JVM_CONSTANT_NameAndType = 12, JVM_CONSTANT_MethodHandle = 15, // JSR 292 - JVM_CONSTANT_MethodType = 16, // JSR 292 - JVM_CONSTANT_InvokeDynamic = 18 + JVM_CONSTANT_MethodType = 16, // JSR 292 + JVM_CONSTANT_InvokeDynamic = 18, + JVM_CONSTANT_ExternalMax = 18 }; /* JVM_CONSTANT_MethodHandle subtypes */ --- old/src/java.base/share/native/include/jvm.h 2017-10-25 08:23:43.725948098 -0400 +++ new/src/java.base/share/native/include/jvm.h 2017-10-25 08:23:43.389539932 -0400 @@ -1155,20 +1155,25 @@ * be renamed to JVM_* in the future? */ -/* - * BE CAREFUL! The following functions do not implement the - * full feature set of standard C printf formats. - */ -int +/* jio_snprintf() and jio_vsnprintf() behave like snprintf(3) and vsnprintf(3), + * respectively, with the following differences: + * - The string written to str is always zero-terminated, also in case of + * truncation (count is too small to hold the result string), unless count + * is 0. In case of truncation count-1 characters are written and '\0' + * appendend. + * - If count is too small to hold the whole string, -1 is returned across + * all platforms. */ + +JNIEXPORT int jio_vsnprintf(char *str, size_t count, const char *fmt, va_list args); -int +JNIEXPORT int jio_snprintf(char *str, size_t count, const char *fmt, ...); -int +JNIEXPORT int jio_fprintf(FILE *, const char *fmt, ...); -int +JNIEXPORT int jio_vfprintf(FILE *, const char *fmt, va_list args); --- old/src/java.base/solaris/native/libjsig/jsig.c 2017-10-25 08:23:53.052994833 -0400 +++ new/src/java.base/solaris/native/libjsig/jsig.c 2017-10-25 08:23:52.619202698 -0400 @@ -37,7 +37,7 @@ #include #include #include -#include "jvm_solaris.h" +#include "jvm_md.h" #define bool int #define true 1 --- old/src/java.base/unix/native/include/jni_md.h 2017-10-25 08:24:02.479596803 -0400 +++ new/src/java.base/unix/native/include/jni_md.h 2017-10-25 08:24:02.049055843 -0400 @@ -30,8 +30,13 @@ #define __has_attribute(x) 0 #endif #if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) - #define JNIEXPORT __attribute__((visibility("default"))) - #define JNIIMPORT __attribute__((visibility("default"))) + #ifdef ARM + #define JNIEXPORT __attribute__((externally_visible,visibility("default"))) + #define JNIIMPORT __attribute__((externally_visible,visibility("default"))) + #else + #define JNIEXPORT __attribute__((visibility("default"))) + #define JNIIMPORT __attribute__((visibility("default"))) + #endif #else #define JNIEXPORT #define JNIIMPORT @@ -40,7 +45,7 @@ #define JNICALL typedef int jint; -#ifdef _LP64 /* 64-bit Solaris */ +#ifdef _LP64 typedef long jlong; #else typedef long long jlong; --- old/src/java.base/unix/native/include/jvm_md.h 2017-10-25 08:24:11.170543291 -0400 +++ new/src/java.base/unix/native/include/jvm_md.h 2017-10-25 08:24:10.821649674 -0400 @@ -39,6 +39,10 @@ #define JNI_ONLOAD_SYMBOLS {"JNI_OnLoad"} #define JNI_ONUNLOAD_SYMBOLS {"JNI_OnUnload"} +#define JVM_ONLOAD_SYMBOLS {"JVM_OnLoad"} +#define AGENT_ONLOAD_SYMBOLS {"Agent_OnLoad"} +#define AGENT_ONUNLOAD_SYMBOLS {"Agent_OnUnload"} +#define AGENT_ONATTACH_SYMBOLS {"Agent_OnAttach"} #define JNI_LIB_PREFIX "lib" #ifdef __APPLE__ @@ -50,7 +54,11 @@ #endif #define JNI_LIB_NAME(NAME) JNI_LIB_PREFIX NAME JNI_LIB_SUFFIX -#define JVM_MAXPATHLEN MAXPATHLEN +// Hack: MAXPATHLEN is 4095 on some Linux and 4096 on others. This may +// cause problems if JVM and the rest of JDK are built on different +// Linux releases. Here we define JVM_MAXPATHLEN to be MAXPATHLEN + 1, +// so buffers declared in VM are always >= 4096. +#define JVM_MAXPATHLEN MAXPATHLEN + 1 #define JVM_R_OK R_OK #define JVM_W_OK W_OK @@ -67,19 +75,20 @@ #include #include -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - /* Signals */ +#include // for socklen_t + #define JVM_SIGINT SIGINT #define JVM_SIGTERM SIGTERM +#define BREAK_SIGNAL SIGQUIT /* Thread dumping support. */ +#define ASYNC_SIGNAL SIGJVM2 /* Event-based suspend/resume support */ +#define SHUTDOWN1_SIGNAL SIGHUP /* Shutdown Hooks support. */ +#define SHUTDOWN2_SIGNAL SIGINT +#define SHUTDOWN3_SIGNAL SIGTERM + +/* With 1.4.1 libjsig added versioning: used in os_solaris.cpp and jsig.c */ +#define JSIG_VERSION_1_4_1 0x30140100 #endif /* !_JAVASOFT_JVM_MD_H_ */ --- old/src/java.base/windows/native/include/jni_md.h 2017-10-25 08:24:20.541674241 -0400 +++ new/src/java.base/windows/native/include/jni_md.h 2017-10-25 08:24:20.095964831 -0400 @@ -30,6 +30,7 @@ #define JNIIMPORT __declspec(dllimport) #define JNICALL __stdcall +// 'long' is always 32 bit on windows so this matches what jdk expects typedef long jint; typedef __int64 jlong; typedef signed char jbyte; --- old/src/java.base/windows/native/include/jvm_md.h 2017-10-25 08:24:28.849835461 -0400 +++ new/src/java.base/windows/native/include/jvm_md.h 2017-10-25 08:24:28.515050453 -0400 @@ -31,13 +31,20 @@ * JNI conversion, which should be sorted out later. */ +#include #include #include #include "jni.h" +typedef int socklen_t; + #define JNI_ONLOAD_SYMBOLS {"_JNI_OnLoad@8", "JNI_OnLoad"} #define JNI_ONUNLOAD_SYMBOLS {"_JNI_OnUnload@8", "JNI_OnUnload"} +#define JVM_ONLOAD_SYMBOLS {"_JVM_OnLoad@12", "JVM_OnLoad"} +#define AGENT_ONLOAD_SYMBOLS {"_Agent_OnLoad@12", "Agent_OnLoad"} +#define AGENT_ONUNLOAD_SYMBOLS {"_Agent_OnUnload@4", "Agent_OnUnload"} +#define AGENT_ONATTACH_SYMBOLS {"_Agent_OnAttach@12", "Agent_OnAttach"} #define JNI_LIB_PREFIX "" #define JNI_LIB_SUFFIX ".dll" @@ -63,21 +70,16 @@ #define JVM_X_OK 1 #define JVM_F_OK 0 +#ifdef __cplusplus +extern "C" { +#endif + JNIEXPORT void * JNICALL JVM_GetThreadInterruptEvent(); -/* - * These routines are only reentrant on Windows - */ - -JNIEXPORT struct protoent * JNICALL -JVM_GetProtoByName(char* name); - -JNIEXPORT struct hostent* JNICALL -JVM_GetHostByAddr(const char* name, int len, int type); - -JNIEXPORT struct hostent* JNICALL -JVM_GetHostByName(char* name); +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ /* * File I/O @@ -89,19 +91,12 @@ #include #include -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - /* Signals */ #define JVM_SIGINT SIGINT #define JVM_SIGTERM SIGTERM +#define SHUTDOWN1_SIGNAL SIGINT /* Shutdown Hooks support. */ +#define SHUTDOWN2_SIGNAL SIGTERM #endif /* !_JAVASOFT_JVM_MD_H_ */ --- old/test/hotspot/gtest/classfile/test_AltHashing.cpp 2017-10-25 08:24:38.950680839 -0400 +++ new/test/hotspot/gtest/classfile/test_AltHashing.cpp 2017-10-25 08:24:38.514121315 -0400 @@ -51,7 +51,7 @@ class AltHashingTest : public ::testing::Test { public: - static juint murmur3_32(const int* data, int len) { + static juint murmur3_32(const jint* data, int len) { return AltHashing::murmur3_32(data, len); } }; --- old/test/hotspot/gtest/logging/logTestFixture.cpp 2017-10-25 08:24:47.343099992 -0400 +++ new/test/hotspot/gtest/logging/logTestFixture.cpp 2017-10-25 08:24:46.927459815 -0400 @@ -22,11 +22,11 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "logTestFixture.hpp" #include "logTestUtils.inline.hpp" #include "logging/logConfiguration.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "unittest.hpp" #include "utilities/ostream.hpp" --- old/test/hotspot/gtest/logging/test_log.cpp 2017-10-25 08:24:55.605330909 -0400 +++ new/test/hotspot/gtest/logging/test_log.cpp 2017-10-25 08:24:55.218780964 -0400 @@ -22,11 +22,11 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "gc/shared/gcTraceTime.inline.hpp" #include "logTestFixture.hpp" #include "logTestUtils.inline.hpp" #include "logging/log.hpp" -#include "prims/jvm.h" #include "unittest.hpp" class LogTest : public LogTestFixture { --- old/test/hotspot/gtest/logging/test_logConfiguration.cpp 2017-10-25 08:25:03.914239795 -0400 +++ new/test/hotspot/gtest/logging/test_logConfiguration.cpp 2017-10-25 08:25:03.571854432 -0400 @@ -22,6 +22,7 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "logTestFixture.hpp" #include "logTestUtils.inline.hpp" #include "logging/logConfiguration.hpp" @@ -31,7 +32,6 @@ #include "logging/logTag.hpp" #include "logging/logTagSet.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "unittest.hpp" #include "utilities/ostream.hpp" --- old/test/hotspot/gtest/logging/test_logDecorators.cpp 2017-10-25 08:25:12.546454365 -0400 +++ new/test/hotspot/gtest/logging/test_logDecorators.cpp 2017-10-25 08:25:12.214076816 -0400 @@ -22,8 +22,8 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/logDecorators.hpp" -#include "prims/jvm.h" #include "unittest.hpp" static LogDecorators::Decorator decorator_array[] = { --- old/test/hotspot/gtest/logging/test_logFileOutput.cpp 2017-10-25 08:25:20.764388835 -0400 +++ new/test/hotspot/gtest/logging/test_logFileOutput.cpp 2017-10-25 08:25:20.448543043 -0400 @@ -22,10 +22,10 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "logTestUtils.inline.hpp" #include "logging/logFileOutput.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "runtime/os.hpp" #include "unittest.hpp" #include "utilities/globalDefinitions.hpp" --- old/test/hotspot/gtest/logging/test_logMessageTest.cpp 2017-10-25 08:25:28.858227469 -0400 +++ new/test/hotspot/gtest/logging/test_logMessageTest.cpp 2017-10-25 08:25:28.538680034 -0400 @@ -22,11 +22,11 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "logTestFixture.hpp" #include "logTestUtils.inline.hpp" #include "logging/log.hpp" #include "logging/logMessage.hpp" -#include "prims/jvm.h" #include "unittest.hpp" #include "utilities/globalDefinitions.hpp" --- old/test/hotspot/gtest/logging/test_logTagLevelExpression.cpp 2017-10-25 08:25:37.098820775 -0400 +++ new/test/hotspot/gtest/logging/test_logTagLevelExpression.cpp 2017-10-25 08:25:36.763203769 -0400 @@ -22,10 +22,10 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "logging/logLevel.hpp" #include "logging/logTagLevelExpression.hpp" #include "logging/logTagSet.hpp" -#include "prims/jvm.h" #include "unittest.hpp" #include "utilities/globalDefinitions.hpp" --- old/test/hotspot/gtest/logging/test_logTagSetDescriptions.cpp 2017-10-25 08:25:45.153137101 -0400 +++ new/test/hotspot/gtest/logging/test_logTagSetDescriptions.cpp 2017-10-25 08:25:44.836551313 -0400 @@ -22,12 +22,12 @@ * */ #include "precompiled.hpp" +#include "jvm.h" #include "logTestUtils.inline.hpp" #include "logging/logConfiguration.hpp" #include "logging/logTagSet.hpp" #include "logging/logTagSetDescriptions.hpp" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "unittest.hpp" #include "utilities/ostream.hpp" --- old/test/hotspot/gtest/runtime/test_arguments.cpp 2017-10-25 08:25:53.720653439 -0400 +++ new/test/hotspot/gtest/runtime/test_arguments.cpp 2017-10-25 08:25:53.259866682 -0400 @@ -22,9 +22,9 @@ */ #include "precompiled.hpp" -#include "prims/jvm.h" -#include "runtime/arguments.hpp" +#include "jvm.h" #include "unittest.hpp" +#include "runtime/arguments.hpp" #include "utilities/align.hpp" #include "utilities/globalDefinitions.hpp" --- old/test/hotspot/gtest/utilities/test_json.cpp 2017-10-25 08:26:02.216763446 -0400 +++ new/test/hotspot/gtest/utilities/test_json.cpp 2017-10-25 08:26:01.747405727 -0400 @@ -22,8 +22,8 @@ */ #include "precompiled.hpp" +#include "jvm.h" #include "memory/resourceArea.hpp" -#include "prims/jvm.h" #include "utilities/json.hpp" #include "unittest.hpp" --- old/src/hotspot/cpu/aarch64/jni_aarch64.h 2017-10-25 08:26:11.104697187 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,60 +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. 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 _JAVASOFT_JNI_MD_H_ -#define _JAVASOFT_JNI_MD_H_ - -#if defined(SOLARIS) || defined(LINUX) || defined(_ALLBSD_SOURCE) - - -// Note: please do not change these without also changing jni_md.h in the JDK -// repository -#ifndef __has_attribute - #define __has_attribute(x) 0 -#endif -#if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) - #define JNIEXPORT __attribute__((visibility("default"))) - #define JNIIMPORT __attribute__((visibility("default"))) -#else - #define JNIEXPORT - #define JNIIMPORT -#endif - - #define JNICALL - typedef int jint; - typedef long jlong; - -#else - #define JNIEXPORT __declspec(dllexport) - #define JNIIMPORT __declspec(dllimport) - #define JNICALL __stdcall - - typedef int jint; - typedef __int64 jlong; -#endif - -typedef signed char jbyte; - -#endif /* !_JAVASOFT_JNI_MD_H_ */ --- old/src/hotspot/cpu/arm/jni_arm.h 2017-10-25 08:26:15.016841164 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,52 +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. 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 _JAVASOFT_JNI_MD_H_ -#define _JAVASOFT_JNI_MD_H_ - -// Note: please do not change these without also changing jni_md.h in the JDK -// repository -#ifndef __has_attribute - #define __has_attribute(x) 0 -#endif -#if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) - #define JNIEXPORT __attribute__((externally_visible,visibility("default"))) - #define JNIIMPORT __attribute__((externally_visible,visibility("default"))) -#else - #define JNIEXPORT - #define JNIIMPORT -#endif - -#define JNICALL - -typedef int jint; -#if defined(_LP64) - typedef long jlong; -#else - typedef long long jlong; -#endif -typedef signed char jbyte; - -#endif /* !_JAVASOFT_JNI_MD_H_ */ --- old/src/hotspot/cpu/ppc/jni_ppc.h 2017-10-25 08:26:18.786814317 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,55 +0,0 @@ -/* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2013 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. 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 CPU_PPC_VM_JNI_PPC_H -#define CPU_PPC_VM_JNI_PPC_H - -// Note: please do not change these without also changing jni_md.h in the JDK -// repository -#ifndef __has_attribute - #define __has_attribute(x) 0 -#endif -#if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) - #define JNIEXPORT __attribute__((visibility("default"))) - #define JNIIMPORT __attribute__((visibility("default"))) -#else - #define JNIEXPORT - #define JNIIMPORT -#endif - -#define JNICALL - -typedef int jint; - -#if defined(_LP64) - typedef long jlong; -#else - typedef long long jlong; -#endif - -typedef signed char jbyte; - -#endif // CPU_PPC_VM_JNI_PPC_H --- old/src/hotspot/cpu/s390/jni_s390.h 2017-10-25 08:26:22.619099927 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,45 +0,0 @@ -/* - * Copyright (c) 2016, 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. - * - * This code is free software; you can redistribute 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. - * - */ - -#ifndef _JAVASOFT_JNI_MD_H_ -#define _JAVASOFT_JNI_MD_H_ - -#if defined(__GNUC__) && (__GNUC__ >= 4) - #define JNIEXPORT __attribute__((visibility("default"))) - #define JNIIMPORT __attribute__((visibility("default"))) -#else - #define JNIEXPORT - #define JNIIMPORT -#endif - -#define JNICALL - -typedef int jint; - -typedef long int jlong; - -typedef signed char jbyte; - -#endif // _JAVASOFT_JNI_MD_H_ --- old/src/hotspot/cpu/sparc/jni_sparc.h 2017-10-25 08:26:26.395957668 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,44 +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. - */ - -// Note: please do not change these without also changing jni_md.h in the JDK -// repository -#ifndef __has_attribute - #define __has_attribute(x) 0 -#endif -#if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) - #define JNIEXPORT __attribute__((visibility("default"))) - #define JNIIMPORT __attribute__((visibility("default"))) -#else - #define JNIEXPORT - #define JNIIMPORT -#endif -#define JNICALL - -typedef int jint; - -typedef long jlong; - -typedef signed char jbyte; --- old/src/hotspot/cpu/x86/jni_x86.h 2017-10-25 08:26:30.386624756 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,63 +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. 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 _JAVASOFT_JNI_MD_H_ -#define _JAVASOFT_JNI_MD_H_ - -#if defined(_WIN32) - #define JNIEXPORT __declspec(dllexport) - #define JNIIMPORT __declspec(dllimport) - #define JNICALL __stdcall - - typedef int jint; - typedef __int64 jlong; -#else - -// Note: please do not change these without also changing jni_md.h in the JDK -// repository -#ifndef __has_attribute - #define __has_attribute(x) 0 -#endif -#if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) - #define JNIEXPORT __attribute__((visibility("default"))) - #define JNIIMPORT __attribute__((visibility("default"))) -#else - #define JNIEXPORT - #define JNIIMPORT -#endif - - #define JNICALL - typedef int jint; -#if defined(_LP64) - typedef long jlong; -#else - typedef long long jlong; -#endif - -#endif - -typedef signed char jbyte; - -#endif /* !_JAVASOFT_JNI_MD_H_ */ --- old/src/hotspot/cpu/zero/jni_zero.h 2017-10-25 08:26:34.177411595 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,50 +0,0 @@ -/* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. - * Copyright 2009 Red Hat, Inc. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute 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. - */ - - - -// Note: please do not change these without also changing jni_md.h in the JDK -// repository -#ifndef __has_attribute - #define __has_attribute(x) 0 -#endif -#if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) - #define JNIEXPORT __attribute__((visibility("default"))) - #define JNIIMPORT __attribute__((visibility("default"))) -#else - #define JNIEXPORT - #define JNIIMPORT -#endif -#define JNICALL - -typedef int jint; -typedef signed char jbyte; - -#ifdef _LP64 -typedef long jlong; -#else -typedef long long jlong; -#endif --- old/src/hotspot/os/aix/jvm_aix.h 2017-10-25 08:26:38.180654698 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,106 +0,0 @@ -/* - * Copyright (c) 1999, 2017, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2013 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. - * - */ - -#ifndef OS_AIX_VM_JVM_AIX_H -#define OS_AIX_VM_JVM_AIX_H - -// HotSpot integration note: -// -// This is derived from the JDK classic file: -// "$JDK/src/solaris/javavm/export/jvm_md.h":15 (ver. 1.10 98/04/22) -// All local includes have been commented out. - -#ifndef JVM_MD_H -#define JVM_MD_H - -/* - * This file is currently collecting system-specific dregs for the - * JNI conversion, which should be sorted out later. - */ - -#include /* For DIR */ - -// Must redefine NULL because the macro gets redefined to int 0 -// by dirent.h. This redefinition is included later then the standard definition in -// globalDefinitions_.hpp and leads to assertions in the VM initialization. -// We definitely need NULL to have the same lengh as an address pointer. -#ifdef _LP64 -#undef NULL -#define NULL 0L -#else -#ifndef NULL -#define NULL 0 -#endif -#endif - -#include /* For MAXPATHLEN */ -#include /* For socklen_t */ -#include /* For F_OK, R_OK, W_OK */ - -#define JNI_ONLOAD_SYMBOLS {"JNI_OnLoad"} -#define JNI_ONUNLOAD_SYMBOLS {"JNI_OnUnload"} -#define JVM_ONLOAD_SYMBOLS {"JVM_OnLoad"} -#define AGENT_ONLOAD_SYMBOLS {"Agent_OnLoad"} -#define AGENT_ONUNLOAD_SYMBOLS {"Agent_OnUnload"} -#define AGENT_ONATTACH_SYMBOLS {"Agent_OnAttach"} - -#define JNI_LIB_PREFIX "lib" -#define JNI_LIB_SUFFIX ".so" - -#define JVM_MAXPATHLEN MAXPATHLEN - -#define JVM_R_OK R_OK -#define JVM_W_OK W_OK -#define JVM_X_OK X_OK -#define JVM_F_OK F_OK - -/* - * File I/O - */ - -#include -#include -#include -#include - -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - -/* Signal definitions */ - -#define BREAK_SIGNAL SIGQUIT /* Thread dumping support. */ -#define SHUTDOWN1_SIGNAL SIGHUP /* Shutdown Hooks support. */ -#define SHUTDOWN2_SIGNAL SIGINT -#define SHUTDOWN3_SIGNAL SIGTERM - -#endif /* JVM_MD_H */ - -#endif // OS_AIX_VM_JVM_AIX_H --- old/src/hotspot/os/bsd/jvm_bsd.h 2017-10-25 08:26:41.940650401 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,115 +0,0 @@ -/* - * 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 - * 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. - * - */ - -#ifndef OS_BSD_VM_JVM_BSD_H -#define OS_BSD_VM_JVM_BSD_H - -/* -// HotSpot integration note: -// -// This is derived from the JDK classic file: -// "$JDK/src/solaris/javavm/export/jvm_md.h":15 (ver. 1.10 98/04/22) -// All local includes have been commented out. -*/ - -#ifndef JVM_MD_H -#define JVM_MD_H - -/* - * This file is currently collecting system-specific dregs for the - * JNI conversion, which should be sorted out later. - */ - -#include /* For DIR */ -#include /* For MAXPATHLEN */ -#include /* For socklen_t */ -#include /* For F_OK, R_OK, W_OK */ - -#define JNI_ONLOAD_SYMBOLS {"JNI_OnLoad"} -#define JNI_ONUNLOAD_SYMBOLS {"JNI_OnUnload"} -#define JVM_ONLOAD_SYMBOLS {"JVM_OnLoad"} -#define AGENT_ONLOAD_SYMBOLS {"Agent_OnLoad"} -#define AGENT_ONUNLOAD_SYMBOLS {"Agent_OnUnload"} -#define AGENT_ONATTACH_SYMBOLS {"Agent_OnAttach"} - -#define JNI_LIB_PREFIX "lib" -#ifdef __APPLE__ -#define JNI_LIB_SUFFIX ".dylib" -#else -#define JNI_LIB_SUFFIX ".so" -#endif - -// Hack: MAXPATHLEN is 4095 on some Bsd and 4096 on others. This may -// cause problems if JVM and the rest of JDK are built on different -// Bsd releases. Here we define JVM_MAXPATHLEN to be MAXPATHLEN + 1, -// so buffers declared in VM are always >= 4096. -#define JVM_MAXPATHLEN MAXPATHLEN + 1 - -#define JVM_R_OK R_OK -#define JVM_W_OK W_OK -#define JVM_X_OK X_OK -#define JVM_F_OK F_OK - -/* - * File I/O - */ - -#include -#include -#include -#include - -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - -/* Signal definitions */ - -#define BREAK_SIGNAL SIGQUIT /* Thread dumping support. */ -#define SHUTDOWN1_SIGNAL SIGHUP /* Shutdown Hooks support. */ -#define SHUTDOWN2_SIGNAL SIGINT -#define SHUTDOWN3_SIGNAL SIGTERM - -#ifndef SIGRTMIN -#ifdef __OpenBSD__ -#define SIGRTMIN 1 -#else -#define SIGRTMIN 33 -#endif -#endif -#ifndef SIGRTMAX -#ifdef __OpenBSD__ -#define SIGRTMAX 31 -#else -#define SIGRTMAX 63 -#endif -#endif -#endif /* JVM_MD_H */ - -#endif // OS_BSD_VM_JVM_BSD_H --- old/src/hotspot/os/linux/jvm_linux.h 2017-10-25 08:26:45.738202746 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,97 +0,0 @@ -/* - * Copyright (c) 1999, 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. - * - */ - -#ifndef OS_LINUX_VM_JVM_LINUX_H -#define OS_LINUX_VM_JVM_LINUX_H - -/* -// HotSpot integration note: -// -// This is derived from the JDK classic file: -// "$JDK/src/solaris/javavm/export/jvm_md.h":15 (ver. 1.10 98/04/22) -// All local includes have been commented out. -*/ - -#ifndef JVM_MD_H -#define JVM_MD_H - -/* - * This file is currently collecting system-specific dregs for the - * JNI conversion, which should be sorted out later. - */ - -#include /* For DIR */ -#include /* For MAXPATHLEN */ -#include /* For socklen_t */ -#include /* For F_OK, R_OK, W_OK */ - -#define JNI_ONLOAD_SYMBOLS {"JNI_OnLoad"} -#define JNI_ONUNLOAD_SYMBOLS {"JNI_OnUnload"} -#define JVM_ONLOAD_SYMBOLS {"JVM_OnLoad"} -#define AGENT_ONLOAD_SYMBOLS {"Agent_OnLoad"} -#define AGENT_ONUNLOAD_SYMBOLS {"Agent_OnUnload"} -#define AGENT_ONATTACH_SYMBOLS {"Agent_OnAttach"} - -#define JNI_LIB_PREFIX "lib" -#define JNI_LIB_SUFFIX ".so" - -// Hack: MAXPATHLEN is 4095 on some Linux and 4096 on others. This may -// cause problems if JVM and the rest of JDK are built on different -// Linux releases. Here we define JVM_MAXPATHLEN to be MAXPATHLEN + 1, -// so buffers declared in VM are always >= 4096. -#define JVM_MAXPATHLEN MAXPATHLEN + 1 - -#define JVM_R_OK R_OK -#define JVM_W_OK W_OK -#define JVM_X_OK X_OK -#define JVM_F_OK F_OK - -/* - * File I/O - */ - -#include -#include -#include -#include - -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - -/* Signal definitions */ - -#define BREAK_SIGNAL SIGQUIT /* Thread dumping support. */ -#define SHUTDOWN1_SIGNAL SIGHUP /* Shutdown Hooks support. */ -#define SHUTDOWN2_SIGNAL SIGINT -#define SHUTDOWN3_SIGNAL SIGTERM - -#endif /* JVM_MD_H */ - -#endif // OS_LINUX_VM_JVM_LINUX_H --- old/src/hotspot/os/solaris/jvm_solaris.h 2017-10-25 08:26:49.545581595 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,98 +0,0 @@ -/* - * 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 - * 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. - * - */ - -#ifndef OS_SOLARIS_VM_JVM_SOLARIS_H -#define OS_SOLARIS_VM_JVM_SOLARIS_H - -/* -// HotSpot integration note: -// -// This is derived from the JDK classic file: -// "$JDK/src/solaris/javavm/export/jvm_md.h":15 (ver. 1.10 98/04/22) -// All local includes have been commented out. -*/ - -#ifndef JVM_MD_H -#define JVM_MD_H - -/* - * This file is currently collecting system-specific dregs for the - * JNI conversion, which should be sorted out later. - */ - -#include /* For DIR */ -#include /* For MAXPATHLEN */ -#include /* For socklen_t */ -#include /* For F_OK, R_OK, W_OK */ -#include /* for intptr_t types (64 Bit cleanliness) */ - -#define JNI_ONLOAD_SYMBOLS {"JNI_OnLoad"} -#define JNI_ONUNLOAD_SYMBOLS {"JNI_OnUnload"} -#define JVM_ONLOAD_SYMBOLS {"JVM_OnLoad"} -#define AGENT_ONLOAD_SYMBOLS {"Agent_OnLoad"} -#define AGENT_ONUNLOAD_SYMBOLS {"Agent_OnUnload"} -#define AGENT_ONATTACH_SYMBOLS {"Agent_OnAttach"} - -#define JNI_LIB_PREFIX "lib" -#define JNI_LIB_SUFFIX ".so" - -#define JVM_MAXPATHLEN MAXPATHLEN - -#define JVM_R_OK R_OK -#define JVM_W_OK W_OK -#define JVM_X_OK X_OK -#define JVM_F_OK F_OK - -/* - * File I/O - */ - -#include -#include -#include -#include - -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - -/* Signal definitions */ - -#define BREAK_SIGNAL SIGQUIT /* Thread dumping support. */ -#define ASYNC_SIGNAL SIGJVM2 /* Event-based suspend/resume support */ -#define SHUTDOWN1_SIGNAL SIGHUP /* Shutdown Hooks support. */ -#define SHUTDOWN2_SIGNAL SIGINT -#define SHUTDOWN3_SIGNAL SIGTERM - -/* With 1.4.1 libjsig added versioning: used in os_solaris.cpp and jsig.c */ -#define JSIG_VERSION_1_4_1 0x30140100 - -#endif /* JVM_MD_H */ - -#endif // OS_SOLARIS_VM_JVM_SOLARIS_H --- old/src/hotspot/os/windows/jvm_windows.h 2017-10-25 08:26:53.403431344 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,118 +0,0 @@ -/* - * Copyright (c) 1998, 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. - * - */ - -#ifndef OS_WINDOWS_VM_JVM_WINDOWS_H -#define OS_WINDOWS_VM_JVM_WINDOWS_H - -#ifndef _JAVASOFT_JVM_MD_H_ -#define _JAVASOFT_JVM_MD_H_ - -/* - * This file is currently collecting system-specific dregs for the - * JNI conversion, which should be sorted out later. - */ - -// JDK7 requires VS2010 -#if _MSC_VER >= 1600 -// JDK7 minimum platform requirement: Windows XP -#if _WIN32_WINNT < 0x0501 -#undef _WIN32_WINNT -#define _WIN32_WINNT 0x0501 -#endif -#endif - -#include - -#include -#include - -typedef int socklen_t; - -#define JNI_ONLOAD_SYMBOLS {"_JNI_OnLoad@8", "JNI_OnLoad"} -#define JNI_ONUNLOAD_SYMBOLS {"_JNI_OnUnload@8", "JNI_OnUnload"} -#define JVM_ONLOAD_SYMBOLS {"_JVM_OnLoad@12", "JVM_OnLoad"} -#define AGENT_ONLOAD_SYMBOLS {"_Agent_OnLoad@12", "Agent_OnLoad"} -#define AGENT_ONUNLOAD_SYMBOLS {"_Agent_OnUnload@4", "Agent_OnUnload"} -#define AGENT_ONATTACH_SYMBOLS {"_Agent_OnAttach@12", "Agent_OnAttach"} - -#define JNI_LIB_PREFIX "" -#define JNI_LIB_SUFFIX ".dll" - -struct dirent { - char d_name[MAX_PATH]; -}; - -typedef struct { - struct dirent dirent; - char *path; - HANDLE handle; - WIN32_FIND_DATA find_data; -} DIR; - -#include - -#define JVM_MAXPATHLEN _MAX_PATH - -#define JVM_R_OK 4 -#define JVM_W_OK 2 -#define JVM_X_OK 1 -#define JVM_F_OK 0 - -#ifdef __cplusplus -extern "C" { -#endif - -JNIEXPORT void * JNICALL -JVM_GetThreadInterruptEvent(); - -#ifdef __cplusplus -} /* extern "C" */ -#endif /* __cplusplus */ - -/* - * File I/O - */ - -#include - -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - -/* Signals */ - -#define JVM_SIGINT SIGINT -#define JVM_SIGTERM SIGTERM - -#define SHUTDOWN1_SIGNAL SIGINT /* Shutdown Hooks support. */ -#define SHUTDOWN2_SIGNAL SIGTERM - -#endif /* !_JAVASOFT_JVM_MD_H_ */ - -#endif // OS_WINDOWS_VM_JVM_WINDOWS_H --- old/src/hotspot/share/prims/jni_md.h 2017-10-25 08:26:57.339281143 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,39 +0,0 @@ -/* - * Copyright (c) 1997, 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. 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. - */ - -#include "utilities/macros.hpp" - -/* Switch to the correct jni_md.h file without reliance on -I options. */ -#include CPU_HEADER_H(jni) - -/* - The local copies of JNI header files may be refreshed - from a JDK distribution by means of these commands: - - cp ${JDK_DIST}/solaris/include/solaris/jni_md.h ./jni_sparc.h - cp ${JDK_DIST}/win32/include/win32/jni_md.h ./jni_i486.h - cp ${JDK_DIST}/win32/include/jni.h ./jni.h - -*/ --- old/src/hotspot/share/prims/jvm.h 2017-10-25 08:27:01.189059916 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,1373 +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. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please 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 SHARE_VM_PRIMS_JVM_H -#define SHARE_VM_PRIMS_JVM_H - -#include "jni.h" -#include "utilities/macros.hpp" - -#include OS_HEADER_H(jvm) - -#ifndef _JAVASOFT_JVM_H_ -#define _JAVASOFT_JVM_H_ - -// HotSpot integration note: -// -// This file and jvm.h used with the JDK are identical, -// except for the three includes removed below - -// #include -// #include "jni.h" -// #include "jvm_md.h" - - -#ifdef __cplusplus -extern "C" { -#endif - -/* - * This file contains additional functions exported from the VM. - * These functions are complementary to the standard JNI support. - * There are three parts to this file: - * - * First, this file contains the VM-related functions needed by native - * libraries in the standard Java API. For example, the java.lang.Object - * class needs VM-level functions that wait for and notify monitors. - * - * Second, this file contains the functions and constant definitions - * needed by the byte code verifier and class file format checker. - * These functions allow the verifier and format checker to be written - * in a VM-independent way. - * - * Third, this file contains various I/O and nerwork operations needed - * by the standard Java I/O and network APIs. - */ - -/* - * Bump the version number when either of the following happens: - * - * 1. There is a change in JVM_* functions. - * - * 2. There is a change in the contract between VM and Java classes. - * For example, if the VM relies on a new private field in Thread - * class. - */ - -#define JVM_INTERFACE_VERSION 5 - -JNIEXPORT jobjectArray JNICALL -JVM_GetMethodParameters(JNIEnv *env, jobject method); - -JNIEXPORT jint JNICALL -JVM_GetInterfaceVersion(void); - -/************************************************************************* - PART 1: Functions for Native Libraries - ************************************************************************/ -/* - * java.lang.Object - */ -JNIEXPORT jint JNICALL -JVM_IHashCode(JNIEnv *env, jobject obj); - -JNIEXPORT void JNICALL -JVM_MonitorWait(JNIEnv *env, jobject obj, jlong ms); - -JNIEXPORT void JNICALL -JVM_MonitorNotify(JNIEnv *env, jobject obj); - -JNIEXPORT void JNICALL -JVM_MonitorNotifyAll(JNIEnv *env, jobject obj); - -JNIEXPORT jobject JNICALL -JVM_Clone(JNIEnv *env, jobject obj); - -/* - * java.lang.String - */ -JNIEXPORT jstring JNICALL -JVM_InternString(JNIEnv *env, jstring str); - -/* - * java.lang.System - */ -JNIEXPORT jlong JNICALL -JVM_CurrentTimeMillis(JNIEnv *env, jclass ignored); - -JNIEXPORT jlong JNICALL -JVM_NanoTime(JNIEnv *env, jclass ignored); - -JNIEXPORT jlong JNICALL -JVM_GetNanoTimeAdjustment(JNIEnv *env, jclass ignored, jlong offset_secs); - -JNIEXPORT void JNICALL -JVM_ArrayCopy(JNIEnv *env, jclass ignored, jobject src, jint src_pos, - jobject dst, jint dst_pos, jint length); - -JNIEXPORT jobject JNICALL -JVM_InitProperties(JNIEnv *env, jobject p); - -/* - * java.lang.Runtime - */ - -JNIEXPORT void JNICALL -JVM_Halt(jint code); - -JNIEXPORT void JNICALL -JVM_GC(void); - -/* Returns the number of real-time milliseconds that have elapsed since the - * least-recently-inspected heap object was last inspected by the garbage - * collector. - * - * For simple stop-the-world collectors this value is just the time - * since the most recent collection. For generational collectors it is the - * time since the oldest generation was most recently collected. Other - * collectors are free to return a pessimistic estimate of the elapsed time, or - * simply the time since the last full collection was performed. - * - * Note that in the presence of reference objects, a given object that is no - * longer strongly reachable may have to be inspected multiple times before it - * can be reclaimed. - */ -JNIEXPORT jlong JNICALL -JVM_MaxObjectInspectionAge(void); - -JNIEXPORT jlong JNICALL -JVM_TotalMemory(void); - -JNIEXPORT jlong JNICALL -JVM_FreeMemory(void); - -JNIEXPORT jlong JNICALL -JVM_MaxMemory(void); - -JNIEXPORT jint JNICALL -JVM_ActiveProcessorCount(void); - -JNIEXPORT void * JNICALL -JVM_LoadLibrary(const char *name); - -JNIEXPORT void JNICALL -JVM_UnloadLibrary(void * handle); - -JNIEXPORT void * JNICALL -JVM_FindLibraryEntry(void *handle, const char *name); - -JNIEXPORT jboolean JNICALL -JVM_IsSupportedJNIVersion(jint version); - -JNIEXPORT jobjectArray JNICALL -JVM_GetVmArguments(JNIEnv *env); - -/* - * java.lang.Throwable - */ -JNIEXPORT void JNICALL -JVM_FillInStackTrace(JNIEnv *env, jobject throwable); - -/* - * java.lang.StackTraceElement - */ -JNIEXPORT void JNICALL -JVM_InitStackTraceElementArray(JNIEnv *env, jobjectArray elements, jobject throwable); - -JNIEXPORT void JNICALL -JVM_InitStackTraceElement(JNIEnv* env, jobject element, jobject stackFrameInfo); - -/* - * java.lang.StackWalker - */ -enum { - JVM_STACKWALK_FILL_CLASS_REFS_ONLY = 0x02, - JVM_STACKWALK_GET_CALLER_CLASS = 0x04, - JVM_STACKWALK_SHOW_HIDDEN_FRAMES = 0x20, - JVM_STACKWALK_FILL_LIVE_STACK_FRAMES = 0x100 -}; - -JNIEXPORT jobject JNICALL -JVM_CallStackWalk(JNIEnv *env, jobject stackStream, jlong mode, - jint skip_frames, jint frame_count, jint start_index, - jobjectArray frames); - -JNIEXPORT jint JNICALL -JVM_MoreStackWalk(JNIEnv *env, jobject stackStream, jlong mode, jlong anchor, - jint frame_count, jint start_index, - jobjectArray frames); - -/* - * java.lang.Thread - */ -JNIEXPORT void JNICALL -JVM_StartThread(JNIEnv *env, jobject thread); - -JNIEXPORT void JNICALL -JVM_StopThread(JNIEnv *env, jobject thread, jobject exception); - -JNIEXPORT jboolean JNICALL -JVM_IsThreadAlive(JNIEnv *env, jobject thread); - -JNIEXPORT void JNICALL -JVM_SuspendThread(JNIEnv *env, jobject thread); - -JNIEXPORT void JNICALL -JVM_ResumeThread(JNIEnv *env, jobject thread); - -JNIEXPORT void JNICALL -JVM_SetThreadPriority(JNIEnv *env, jobject thread, jint prio); - -JNIEXPORT void JNICALL -JVM_Yield(JNIEnv *env, jclass threadClass); - -JNIEXPORT void JNICALL -JVM_Sleep(JNIEnv *env, jclass threadClass, jlong millis); - -JNIEXPORT jobject JNICALL -JVM_CurrentThread(JNIEnv *env, jclass threadClass); - -JNIEXPORT jint JNICALL -JVM_CountStackFrames(JNIEnv *env, jobject thread); - -JNIEXPORT void JNICALL -JVM_Interrupt(JNIEnv *env, jobject thread); - -JNIEXPORT jboolean JNICALL -JVM_IsInterrupted(JNIEnv *env, jobject thread, jboolean clearInterrupted); - -JNIEXPORT jboolean JNICALL -JVM_HoldsLock(JNIEnv *env, jclass threadClass, jobject obj); - -JNIEXPORT void JNICALL -JVM_DumpAllStacks(JNIEnv *env, jclass unused); - -JNIEXPORT jobjectArray JNICALL -JVM_GetAllThreads(JNIEnv *env, jclass dummy); - -JNIEXPORT void JNICALL -JVM_SetNativeThreadName(JNIEnv *env, jobject jthread, jstring name); - -/* getStackTrace() and getAllStackTraces() method */ -JNIEXPORT jobjectArray JNICALL -JVM_DumpThreads(JNIEnv *env, jclass threadClass, jobjectArray threads); - -/* - * java.lang.SecurityManager - */ -JNIEXPORT jclass JNICALL -JVM_CurrentLoadedClass(JNIEnv *env); - -JNIEXPORT jobject JNICALL -JVM_CurrentClassLoader(JNIEnv *env); - -JNIEXPORT jobjectArray JNICALL -JVM_GetClassContext(JNIEnv *env); - -JNIEXPORT jint JNICALL -JVM_ClassDepth(JNIEnv *env, jstring name); - -JNIEXPORT jint JNICALL -JVM_ClassLoaderDepth(JNIEnv *env); - -/* - * java.lang.Package - */ -JNIEXPORT jstring JNICALL -JVM_GetSystemPackage(JNIEnv *env, jstring name); - -JNIEXPORT jobjectArray JNICALL -JVM_GetSystemPackages(JNIEnv *env); - -/* - * java.lang.ref.Reference - */ -JNIEXPORT jobject JNICALL -JVM_GetAndClearReferencePendingList(JNIEnv *env); - -JNIEXPORT jboolean JNICALL -JVM_HasReferencePendingList(JNIEnv *env); - -JNIEXPORT void JNICALL -JVM_WaitForReferencePendingList(JNIEnv *env); - -/* - * java.io.ObjectInputStream - */ -JNIEXPORT jobject JNICALL -JVM_LatestUserDefinedLoader(JNIEnv *env); - -/* - * java.lang.reflect.Array - */ -JNIEXPORT jint JNICALL -JVM_GetArrayLength(JNIEnv *env, jobject arr); - -JNIEXPORT jobject JNICALL -JVM_GetArrayElement(JNIEnv *env, jobject arr, jint index); - -JNIEXPORT jvalue JNICALL -JVM_GetPrimitiveArrayElement(JNIEnv *env, jobject arr, jint index, jint wCode); - -JNIEXPORT void JNICALL -JVM_SetArrayElement(JNIEnv *env, jobject arr, jint index, jobject val); - -JNIEXPORT void JNICALL -JVM_SetPrimitiveArrayElement(JNIEnv *env, jobject arr, jint index, jvalue v, - unsigned char vCode); - -JNIEXPORT jobject JNICALL -JVM_NewArray(JNIEnv *env, jclass eltClass, jint length); - -JNIEXPORT jobject JNICALL -JVM_NewMultiArray(JNIEnv *env, jclass eltClass, jintArray dim); - -/* - * java.lang.Class and java.lang.ClassLoader - */ - -#define JVM_CALLER_DEPTH -1 - -/* - * Returns the class in which the code invoking the native method - * belongs. - * - * Note that in JDK 1.1, native methods did not create a frame. - * In 1.2, they do. Therefore native methods like Class.forName - * can no longer look at the current frame for the caller class. - */ -JNIEXPORT jclass JNICALL -JVM_GetCallerClass(JNIEnv *env, int n); - -/* - * Find primitive classes - * utf: class name - */ -JNIEXPORT jclass JNICALL -JVM_FindPrimitiveClass(JNIEnv *env, const char *utf); - -/* - * Find a class from a boot class loader. Returns NULL if class not found. - */ -JNIEXPORT jclass JNICALL -JVM_FindClassFromBootLoader(JNIEnv *env, const char *name); - -/* - * Find a class from a given class loader. Throws ClassNotFoundException. - * name: name of class - * init: whether initialization is done - * loader: class loader to look up the class. This may not be the same as the caller's - * class loader. - * caller: initiating class. The initiating class may be null when a security - * manager is not installed. - */ -JNIEXPORT jclass JNICALL -JVM_FindClassFromCaller(JNIEnv *env, const char *name, jboolean init, - jobject loader, jclass caller); - -/* - * Find a class from a given class. - */ -JNIEXPORT jclass JNICALL -JVM_FindClassFromClass(JNIEnv *env, const char *name, jboolean init, - jclass from); - -/* Find a loaded class cached by the VM */ -JNIEXPORT jclass JNICALL -JVM_FindLoadedClass(JNIEnv *env, jobject loader, jstring name); - -/* Define a class */ -JNIEXPORT jclass JNICALL -JVM_DefineClass(JNIEnv *env, const char *name, jobject loader, const jbyte *buf, - jsize len, jobject pd); - -/* Define a class with a source (added in JDK1.5) */ -JNIEXPORT jclass JNICALL -JVM_DefineClassWithSource(JNIEnv *env, const char *name, jobject loader, - const jbyte *buf, jsize len, jobject pd, - const char *source); - -/* - * Module support funcions - */ - -/* - * Define a module with the specified packages and bind the module to the - * given class loader. - * module: module to define - * is_open: specifies if module is open (currently ignored) - * version: the module version - * location: the module location - * packages: list of packages in the module - * num_packages: number of packages in the module - */ -JNIEXPORT void JNICALL -JVM_DefineModule(JNIEnv *env, jobject module, jboolean is_open, jstring version, - jstring location, const char* const* packages, jsize num_packages); - -/* - * Set the boot loader's unnamed module. - * module: boot loader's unnamed module - */ -JNIEXPORT void JNICALL -JVM_SetBootLoaderUnnamedModule(JNIEnv *env, jobject module); - -/* - * Do a qualified export of a package. - * from_module: module containing the package to export - * package: name of the package to export - * to_module: module to export the package to - */ -JNIEXPORT void JNICALL -JVM_AddModuleExports(JNIEnv *env, jobject from_module, const char* package, jobject to_module); - -/* - * Do an export of a package to all unnamed modules. - * from_module: module containing the package to export - * package: name of the package to export to all unnamed modules - */ -JNIEXPORT void JNICALL -JVM_AddModuleExportsToAllUnnamed(JNIEnv *env, jobject from_module, const char* package); - -/* - * Do an unqualified export of a package. - * from_module: module containing the package to export - * package: name of the package to export - */ -JNIEXPORT void JNICALL -JVM_AddModuleExportsToAll(JNIEnv *env, jobject from_module, const char* package); - -/* - * Add a module to the list of modules that a given module can read. - * from_module: module requesting read access - * source_module: module that from_module wants to read - */ -JNIEXPORT void JNICALL -JVM_AddReadsModule(JNIEnv *env, jobject from_module, jobject source_module); - -/* - * Reflection support functions - */ - -JNIEXPORT jstring JNICALL -JVM_GetClassName(JNIEnv *env, jclass cls); - -JNIEXPORT jobjectArray JNICALL -JVM_GetClassInterfaces(JNIEnv *env, jclass cls); - -JNIEXPORT jboolean JNICALL -JVM_IsInterface(JNIEnv *env, jclass cls); - -JNIEXPORT jobjectArray JNICALL -JVM_GetClassSigners(JNIEnv *env, jclass cls); - -JNIEXPORT void JNICALL -JVM_SetClassSigners(JNIEnv *env, jclass cls, jobjectArray signers); - -JNIEXPORT jobject JNICALL -JVM_GetProtectionDomain(JNIEnv *env, jclass cls); - -JNIEXPORT jboolean JNICALL -JVM_IsArrayClass(JNIEnv *env, jclass cls); - -JNIEXPORT jboolean JNICALL -JVM_IsPrimitiveClass(JNIEnv *env, jclass cls); - -JNIEXPORT jint JNICALL -JVM_GetClassModifiers(JNIEnv *env, jclass cls); - -JNIEXPORT jobjectArray JNICALL -JVM_GetDeclaredClasses(JNIEnv *env, jclass ofClass); - -JNIEXPORT jclass JNICALL -JVM_GetDeclaringClass(JNIEnv *env, jclass ofClass); - -JNIEXPORT jstring JNICALL -JVM_GetSimpleBinaryName(JNIEnv *env, jclass ofClass); - -/* Generics support (JDK 1.5) */ -JNIEXPORT jstring JNICALL -JVM_GetClassSignature(JNIEnv *env, jclass cls); - -/* Annotations support (JDK 1.5) */ -JNIEXPORT jbyteArray JNICALL -JVM_GetClassAnnotations(JNIEnv *env, jclass cls); - -/* Annotations support (JDK 1.6) */ - -/* Type use annotations support (JDK 1.8) */ - -JNIEXPORT jbyteArray JNICALL -JVM_GetClassTypeAnnotations(JNIEnv *env, jclass cls); - -// field is a handle to a java.lang.reflect.Field object -JNIEXPORT jbyteArray JNICALL -JVM_GetFieldTypeAnnotations(JNIEnv *env, jobject field); - -// method is a handle to a java.lang.reflect.Method object -JNIEXPORT jbyteArray JNICALL -JVM_GetMethodTypeAnnotations(JNIEnv *env, jobject method); - -/* - * New (JDK 1.4) reflection implementation - */ - -JNIEXPORT jobjectArray JNICALL -JVM_GetClassDeclaredMethods(JNIEnv *env, jclass ofClass, jboolean publicOnly); - -JNIEXPORT jobjectArray JNICALL -JVM_GetClassDeclaredFields(JNIEnv *env, jclass ofClass, jboolean publicOnly); - -JNIEXPORT jobjectArray JNICALL -JVM_GetClassDeclaredConstructors(JNIEnv *env, jclass ofClass, jboolean publicOnly); - -/* Differs from JVM_GetClassModifiers in treatment of inner classes. - This returns the access flags for the class as specified in the - class file rather than searching the InnerClasses attribute (if - present) to find the source-level access flags. Only the values of - the low 13 bits (i.e., a mask of 0x1FFF) are guaranteed to be - valid. */ -JNIEXPORT jint JNICALL -JVM_GetClassAccessFlags(JNIEnv *env, jclass cls); - -/* - * Constant pool access; currently used to implement reflective access to annotations (JDK 1.5) - */ - -JNIEXPORT jobject JNICALL -JVM_GetClassConstantPool(JNIEnv *env, jclass cls); - -JNIEXPORT jint JNICALL JVM_ConstantPoolGetSize -(JNIEnv *env, jobject obj, jobject unused); - -JNIEXPORT jclass JNICALL JVM_ConstantPoolGetClassAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jclass JNICALL JVM_ConstantPoolGetClassAtIfLoaded -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jobject JNICALL JVM_ConstantPoolGetMethodAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jobject JNICALL JVM_ConstantPoolGetMethodAtIfLoaded -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jobject JNICALL JVM_ConstantPoolGetFieldAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jobject JNICALL JVM_ConstantPoolGetFieldAtIfLoaded -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jobjectArray JNICALL JVM_ConstantPoolGetMemberRefInfoAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jobjectArray JNICALL JVM_ConstantPoolGetNameAndTypeRefInfoAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jint JNICALL JVM_ConstantPoolGetNameAndTypeRefIndexAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jint JNICALL JVM_ConstantPoolGetClassRefIndexAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jint JNICALL JVM_ConstantPoolGetIntAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jlong JNICALL JVM_ConstantPoolGetLongAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jfloat JNICALL JVM_ConstantPoolGetFloatAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jdouble JNICALL JVM_ConstantPoolGetDoubleAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jstring JNICALL JVM_ConstantPoolGetStringAt -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jstring JNICALL JVM_ConstantPoolGetUTF8At -(JNIEnv *env, jobject obj, jobject unused, jint index); - -JNIEXPORT jbyte JNICALL JVM_ConstantPoolGetTagAt -(JNIEnv *env, jobject unused, jobject jcpool, jint index); - -/* - * java.security.* - */ - -JNIEXPORT jobject JNICALL -JVM_DoPrivileged(JNIEnv *env, jclass cls, - jobject action, jobject context, jboolean wrapException); - -JNIEXPORT jobject JNICALL -JVM_GetInheritedAccessControlContext(JNIEnv *env, jclass cls); - -JNIEXPORT jobject JNICALL -JVM_GetStackAccessControlContext(JNIEnv *env, jclass cls); - -/* - * Signal support, used to implement the shutdown sequence. Every VM must - * support JVM_SIGINT and JVM_SIGTERM, raising the former for user interrupts - * (^C) and the latter for external termination (kill, system shutdown, etc.). - * Other platform-dependent signal values may also be supported. - */ - -JNIEXPORT void * JNICALL -JVM_RegisterSignal(jint sig, void *handler); - -JNIEXPORT jboolean JNICALL -JVM_RaiseSignal(jint sig); - -JNIEXPORT jint JNICALL -JVM_FindSignal(const char *name); - -/* - * Retrieve the assertion directives for the specified class. - */ -JNIEXPORT jboolean JNICALL -JVM_DesiredAssertionStatus(JNIEnv *env, jclass unused, jclass cls); - -/* - * Retrieve the assertion directives from the VM. - */ -JNIEXPORT jobject JNICALL -JVM_AssertionStatusDirectives(JNIEnv *env, jclass unused); - -/* - * java.util.concurrent.atomic.AtomicLong - */ -JNIEXPORT jboolean JNICALL -JVM_SupportsCX8(void); - -/************************************************************************* - PART 2: Support for the Verifier and Class File Format Checker - ************************************************************************/ -/* - * Return the class name in UTF format. The result is valid - * until JVM_ReleaseUTf is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetClassNameUTF(JNIEnv *env, jclass cb); - -/* - * Returns the constant pool types in the buffer provided by "types." - */ -JNIEXPORT void JNICALL -JVM_GetClassCPTypes(JNIEnv *env, jclass cb, unsigned char *types); - -/* - * Returns the number of Constant Pool entries. - */ -JNIEXPORT jint JNICALL -JVM_GetClassCPEntriesCount(JNIEnv *env, jclass cb); - -/* - * Returns the number of *declared* fields or methods. - */ -JNIEXPORT jint JNICALL -JVM_GetClassFieldsCount(JNIEnv *env, jclass cb); - -JNIEXPORT jint JNICALL -JVM_GetClassMethodsCount(JNIEnv *env, jclass cb); - -/* - * Returns the CP indexes of exceptions raised by a given method. - * Places the result in the given buffer. - * - * The method is identified by method_index. - */ -JNIEXPORT void JNICALL -JVM_GetMethodIxExceptionIndexes(JNIEnv *env, jclass cb, jint method_index, - unsigned short *exceptions); -/* - * Returns the number of exceptions raised by a given method. - * The method is identified by method_index. - */ -JNIEXPORT jint JNICALL -JVM_GetMethodIxExceptionsCount(JNIEnv *env, jclass cb, jint method_index); - -/* - * Returns the byte code sequence of a given method. - * Places the result in the given buffer. - * - * The method is identified by method_index. - */ -JNIEXPORT void JNICALL -JVM_GetMethodIxByteCode(JNIEnv *env, jclass cb, jint method_index, - unsigned char *code); - -/* - * Returns the length of the byte code sequence of a given method. - * The method is identified by method_index. - */ -JNIEXPORT jint JNICALL -JVM_GetMethodIxByteCodeLength(JNIEnv *env, jclass cb, jint method_index); - -/* - * A structure used to a capture exception table entry in a Java method. - */ -typedef struct { - jint start_pc; - jint end_pc; - jint handler_pc; - jint catchType; -} JVM_ExceptionTableEntryType; - -/* - * Returns the exception table entry at entry_index of a given method. - * Places the result in the given buffer. - * - * The method is identified by method_index. - */ -JNIEXPORT void JNICALL -JVM_GetMethodIxExceptionTableEntry(JNIEnv *env, jclass cb, jint method_index, - jint entry_index, - JVM_ExceptionTableEntryType *entry); - -/* - * Returns the length of the exception table of a given method. - * The method is identified by method_index. - */ -JNIEXPORT jint JNICALL -JVM_GetMethodIxExceptionTableLength(JNIEnv *env, jclass cb, int index); - -/* - * Returns the modifiers of a given field. - * The field is identified by field_index. - */ -JNIEXPORT jint JNICALL -JVM_GetFieldIxModifiers(JNIEnv *env, jclass cb, int index); - -/* - * Returns the modifiers of a given method. - * The method is identified by method_index. - */ -JNIEXPORT jint JNICALL -JVM_GetMethodIxModifiers(JNIEnv *env, jclass cb, int index); - -/* - * Returns the number of local variables of a given method. - * The method is identified by method_index. - */ -JNIEXPORT jint JNICALL -JVM_GetMethodIxLocalsCount(JNIEnv *env, jclass cb, int index); - -/* - * Returns the number of arguments (including this pointer) of a given method. - * The method is identified by method_index. - */ -JNIEXPORT jint JNICALL -JVM_GetMethodIxArgsSize(JNIEnv *env, jclass cb, int index); - -/* - * Returns the maximum amount of stack (in words) used by a given method. - * The method is identified by method_index. - */ -JNIEXPORT jint JNICALL -JVM_GetMethodIxMaxStack(JNIEnv *env, jclass cb, int index); - -/* - * Is a given method a constructor. - * The method is identified by method_index. - */ -JNIEXPORT jboolean JNICALL -JVM_IsConstructorIx(JNIEnv *env, jclass cb, int index); - -/* - * Is the given method generated by the VM. - * The method is identified by method_index. - */ -JNIEXPORT jboolean JNICALL -JVM_IsVMGeneratedMethodIx(JNIEnv *env, jclass cb, int index); - -/* - * Returns the name of a given method in UTF format. - * The result remains valid until JVM_ReleaseUTF is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetMethodIxNameUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the signature of a given method in UTF format. - * The result remains valid until JVM_ReleaseUTF is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetMethodIxSignatureUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the name of the field refered to at a given constant pool - * index. - * - * The result is in UTF format and remains valid until JVM_ReleaseUTF - * is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetCPFieldNameUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the name of the method refered to at a given constant pool - * index. - * - * The result is in UTF format and remains valid until JVM_ReleaseUTF - * is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetCPMethodNameUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the signature of the method refered to at a given constant pool - * index. - * - * The result is in UTF format and remains valid until JVM_ReleaseUTF - * is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetCPMethodSignatureUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the signature of the field refered to at a given constant pool - * index. - * - * The result is in UTF format and remains valid until JVM_ReleaseUTF - * is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetCPFieldSignatureUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the class name refered to at a given constant pool index. - * - * The result is in UTF format and remains valid until JVM_ReleaseUTF - * is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetCPClassNameUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the class name refered to at a given constant pool index. - * - * The constant pool entry must refer to a CONSTANT_Fieldref. - * - * The result is in UTF format and remains valid until JVM_ReleaseUTF - * is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetCPFieldClassNameUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the class name refered to at a given constant pool index. - * - * The constant pool entry must refer to CONSTANT_Methodref or - * CONSTANT_InterfaceMethodref. - * - * The result is in UTF format and remains valid until JVM_ReleaseUTF - * is called. - * - * The caller must treat the string as a constant and not modify it - * in any way. - */ -JNIEXPORT const char * JNICALL -JVM_GetCPMethodClassNameUTF(JNIEnv *env, jclass cb, jint index); - -/* - * Returns the modifiers of a field in calledClass. The field is - * referred to in class cb at constant pool entry index. - * - * The caller must treat the string as a constant and not modify it - * in any way. - * - * Returns -1 if the field does not exist in calledClass. - */ -JNIEXPORT jint JNICALL -JVM_GetCPFieldModifiers(JNIEnv *env, jclass cb, int index, jclass calledClass); - -/* - * Returns the modifiers of a method in calledClass. The method is - * referred to in class cb at constant pool entry index. - * - * Returns -1 if the method does not exist in calledClass. - */ -JNIEXPORT jint JNICALL -JVM_GetCPMethodModifiers(JNIEnv *env, jclass cb, int index, jclass calledClass); - -/* - * Releases the UTF string obtained from the VM. - */ -JNIEXPORT void JNICALL -JVM_ReleaseUTF(const char *utf); - -/* - * Compare if two classes are in the same package. - */ -JNIEXPORT jboolean JNICALL -JVM_IsSameClassPackage(JNIEnv *env, jclass class1, jclass class2); - -/* Constants in class files */ - -#define JVM_ACC_PUBLIC 0x0001 /* visible to everyone */ -#define JVM_ACC_PRIVATE 0x0002 /* visible only to the defining class */ -#define JVM_ACC_PROTECTED 0x0004 /* visible to subclasses */ -#define JVM_ACC_STATIC 0x0008 /* instance variable is static */ -#define JVM_ACC_FINAL 0x0010 /* no further subclassing, overriding */ -#define JVM_ACC_SYNCHRONIZED 0x0020 /* wrap method call in monitor lock */ -#define JVM_ACC_SUPER 0x0020 /* funky handling of invokespecial */ -#define JVM_ACC_VOLATILE 0x0040 /* can not cache in registers */ -#define JVM_ACC_BRIDGE 0x0040 /* bridge method generated by compiler */ -#define JVM_ACC_TRANSIENT 0x0080 /* not persistent */ -#define JVM_ACC_VARARGS 0x0080 /* method declared with variable number of args */ -#define JVM_ACC_NATIVE 0x0100 /* implemented in C */ -#define JVM_ACC_INTERFACE 0x0200 /* class is an interface */ -#define JVM_ACC_ABSTRACT 0x0400 /* no definition provided */ -#define JVM_ACC_STRICT 0x0800 /* strict floating point */ -#define JVM_ACC_SYNTHETIC 0x1000 /* compiler-generated class, method or field */ -#define JVM_ACC_ANNOTATION 0x2000 /* annotation type */ -#define JVM_ACC_ENUM 0x4000 /* field is declared as element of enum */ -#define JVM_ACC_MODULE 0x8000 /* module-info class file */ - -#define JVM_ACC_PUBLIC_BIT 0 -#define JVM_ACC_PRIVATE_BIT 1 -#define JVM_ACC_PROTECTED_BIT 2 -#define JVM_ACC_STATIC_BIT 3 -#define JVM_ACC_FINAL_BIT 4 -#define JVM_ACC_SYNCHRONIZED_BIT 5 -#define JVM_ACC_SUPER_BIT 5 -#define JVM_ACC_VOLATILE_BIT 6 -#define JVM_ACC_BRIDGE_BIT 6 -#define JVM_ACC_TRANSIENT_BIT 7 -#define JVM_ACC_VARARGS_BIT 7 -#define JVM_ACC_NATIVE_BIT 8 -#define JVM_ACC_INTERFACE_BIT 9 -#define JVM_ACC_ABSTRACT_BIT 10 -#define JVM_ACC_STRICT_BIT 11 -#define JVM_ACC_SYNTHETIC_BIT 12 -#define JVM_ACC_ANNOTATION_BIT 13 -#define JVM_ACC_ENUM_BIT 14 - -// NOTE: replicated in SA in vm/agent/sun/jvm/hotspot/utilities/ConstantTag.java -enum { - JVM_CONSTANT_Utf8 = 1, - JVM_CONSTANT_Unicode, /* unused */ - JVM_CONSTANT_Integer, - JVM_CONSTANT_Float, - JVM_CONSTANT_Long, - JVM_CONSTANT_Double, - JVM_CONSTANT_Class, - JVM_CONSTANT_String, - JVM_CONSTANT_Fieldref, - JVM_CONSTANT_Methodref, - JVM_CONSTANT_InterfaceMethodref, - JVM_CONSTANT_NameAndType, - JVM_CONSTANT_MethodHandle = 15, // JSR 292 - JVM_CONSTANT_MethodType = 16, // JSR 292 - //JVM_CONSTANT_(unused) = 17, // JSR 292 early drafts only - JVM_CONSTANT_InvokeDynamic = 18, // JSR 292 - JVM_CONSTANT_ExternalMax = 18 // Last tag found in classfiles -}; - -/* JVM_CONSTANT_MethodHandle subtypes */ -enum { - JVM_REF_getField = 1, - JVM_REF_getStatic = 2, - JVM_REF_putField = 3, - JVM_REF_putStatic = 4, - JVM_REF_invokeVirtual = 5, - JVM_REF_invokeStatic = 6, - JVM_REF_invokeSpecial = 7, - JVM_REF_newInvokeSpecial = 8, - JVM_REF_invokeInterface = 9 -}; - -/* Used in the newarray instruction. */ - -#define JVM_T_BOOLEAN 4 -#define JVM_T_CHAR 5 -#define JVM_T_FLOAT 6 -#define JVM_T_DOUBLE 7 -#define JVM_T_BYTE 8 -#define JVM_T_SHORT 9 -#define JVM_T_INT 10 -#define JVM_T_LONG 11 - -/* JVM method signatures */ - -#define JVM_SIGNATURE_ARRAY '[' -#define JVM_SIGNATURE_BYTE 'B' -#define JVM_SIGNATURE_CHAR 'C' -#define JVM_SIGNATURE_CLASS 'L' -#define JVM_SIGNATURE_ENDCLASS ';' -#define JVM_SIGNATURE_ENUM 'E' -#define JVM_SIGNATURE_FLOAT 'F' -#define JVM_SIGNATURE_DOUBLE 'D' -#define JVM_SIGNATURE_FUNC '(' -#define JVM_SIGNATURE_ENDFUNC ')' -#define JVM_SIGNATURE_INT 'I' -#define JVM_SIGNATURE_LONG 'J' -#define JVM_SIGNATURE_SHORT 'S' -#define JVM_SIGNATURE_VOID 'V' -#define JVM_SIGNATURE_BOOLEAN 'Z' - -/* - * A function defined by the byte-code verifier and called by the VM. - * This is not a function implemented in the VM. - * - * Returns JNI_FALSE if verification fails. A detailed error message - * will be places in msg_buf, whose length is specified by buf_len. - */ -typedef jboolean (*verifier_fn_t)(JNIEnv *env, - jclass cb, - char * msg_buf, - jint buf_len); - - -/* - * Support for a VM-independent class format checker. - */ -typedef struct { - unsigned long code; /* byte code */ - unsigned long excs; /* exceptions */ - unsigned long etab; /* catch table */ - unsigned long lnum; /* line number */ - unsigned long lvar; /* local vars */ -} method_size_info; - -typedef struct { - unsigned int constants; /* constant pool */ - unsigned int fields; - unsigned int methods; - unsigned int interfaces; - unsigned int fields2; /* number of static 2-word fields */ - unsigned int innerclasses; /* # of records in InnerClasses attr */ - - method_size_info clinit; /* memory used in clinit */ - method_size_info main; /* used everywhere else */ -} class_size_info; - -/* - * Functions defined in libjava.so to perform string conversions. - * - */ - -typedef jstring (*to_java_string_fn_t)(JNIEnv *env, char *str); - -typedef char *(*to_c_string_fn_t)(JNIEnv *env, jstring s, jboolean *b); - -/* This is the function defined in libjava.so that performs class - * format checks. This functions fills in size information about - * the class file and returns: - * - * 0: good - * -1: out of memory - * -2: bad format - * -3: unsupported version - * -4: bad class name - */ - -typedef jint (*check_format_fn_t)(char *class_name, - unsigned char *data, - unsigned int data_size, - class_size_info *class_size, - char *message_buffer, - jint buffer_length, - jboolean measure_only, - jboolean check_relaxed); - -#define JVM_RECOGNIZED_CLASS_MODIFIERS (JVM_ACC_PUBLIC | \ - JVM_ACC_FINAL | \ - JVM_ACC_SUPER | \ - JVM_ACC_INTERFACE | \ - JVM_ACC_ABSTRACT | \ - JVM_ACC_ANNOTATION | \ - JVM_ACC_ENUM | \ - JVM_ACC_SYNTHETIC) - -#define JVM_RECOGNIZED_FIELD_MODIFIERS (JVM_ACC_PUBLIC | \ - JVM_ACC_PRIVATE | \ - JVM_ACC_PROTECTED | \ - JVM_ACC_STATIC | \ - JVM_ACC_FINAL | \ - JVM_ACC_VOLATILE | \ - JVM_ACC_TRANSIENT | \ - JVM_ACC_ENUM | \ - JVM_ACC_SYNTHETIC) - -#define JVM_RECOGNIZED_METHOD_MODIFIERS (JVM_ACC_PUBLIC | \ - JVM_ACC_PRIVATE | \ - JVM_ACC_PROTECTED | \ - JVM_ACC_STATIC | \ - JVM_ACC_FINAL | \ - JVM_ACC_SYNCHRONIZED | \ - JVM_ACC_BRIDGE | \ - JVM_ACC_VARARGS | \ - JVM_ACC_NATIVE | \ - JVM_ACC_ABSTRACT | \ - JVM_ACC_STRICT | \ - JVM_ACC_SYNTHETIC) - -/* - * This is the function defined in libjava.so to perform path - * canonicalization. VM call this function before opening jar files - * to load system classes. - * - */ - -typedef int (*canonicalize_fn_t)(JNIEnv *env, char *orig, char *out, int len); - -/************************************************************************* - PART 3: I/O and Network Support - ************************************************************************/ - -/* - * Convert a pathname into native format. This function does syntactic - * cleanup, such as removing redundant separator characters. It modifies - * the given pathname string in place. - */ -JNIEXPORT char * JNICALL -JVM_NativePath(char *); - -/* - * The standard printing functions supported by the Java VM. (Should they - * be renamed to JVM_* in the future? - */ - -/* jio_snprintf() and jio_vsnprintf() behave like snprintf(3) and vsnprintf(3), - * respectively, with the following differences: - * - The string written to str is always zero-terminated, also in case of - * truncation (count is too small to hold the result string), unless count - * is 0. In case of truncation count-1 characters are written and '\0' - * appendend. - * - If count is too small to hold the whole string, -1 is returned across - * all platforms. */ -JNIEXPORT int -jio_vsnprintf(char *str, size_t count, const char *fmt, va_list args); - -JNIEXPORT int -jio_snprintf(char *str, size_t count, const char *fmt, ...); - -JNIEXPORT int -jio_fprintf(FILE *, const char *fmt, ...); - -JNIEXPORT int -jio_vfprintf(FILE *, const char *fmt, va_list args); - - -JNIEXPORT void * JNICALL -JVM_RawMonitorCreate(void); - -JNIEXPORT void JNICALL -JVM_RawMonitorDestroy(void *mon); - -JNIEXPORT jint JNICALL -JVM_RawMonitorEnter(void *mon); - -JNIEXPORT void JNICALL -JVM_RawMonitorExit(void *mon); - -/* - * java.lang.reflect.Method - */ -JNIEXPORT jobject JNICALL -JVM_InvokeMethod(JNIEnv *env, jobject method, jobject obj, jobjectArray args0); - -/* - * java.lang.reflect.Constructor - */ -JNIEXPORT jobject JNICALL -JVM_NewInstanceFromConstructor(JNIEnv *env, jobject c, jobjectArray args0); - -/* - * java.lang.management support - */ -JNIEXPORT void* JNICALL -JVM_GetManagement(jint version); - -/* - * com.sun.tools.attach.VirtualMachine support - * - * Initialize the agent properties with the properties maintained in the VM. - */ -JNIEXPORT jobject JNICALL -JVM_InitAgentProperties(JNIEnv *env, jobject agent_props); - -JNIEXPORT jstring JNICALL -JVM_GetTemporaryDirectory(JNIEnv *env); - -/* Generics reflection support. - * - * Returns information about the given class's EnclosingMethod - * attribute, if present, or null if the class had no enclosing - * method. - * - * If non-null, the returned array contains three elements. Element 0 - * is the java.lang.Class of which the enclosing method is a member, - * and elements 1 and 2 are the java.lang.Strings for the enclosing - * method's name and descriptor, respectively. - */ -JNIEXPORT jobjectArray JNICALL -JVM_GetEnclosingMethodInfo(JNIEnv* env, jclass ofClass); - -/* ========================================================================= - * The following defines a private JVM interface that the JDK can query - * for the JVM version and capabilities. sun.misc.Version defines - * the methods for getting the VM version and its capabilities. - * - * When a new bit is added, the following should be updated to provide - * access to the new capability: - * HS: JVM_GetVersionInfo and Abstract_VM_Version class - * SDK: Version class - * - * Similary, a private JDK interface JDK_GetVersionInfo0 is defined for - * JVM to query for the JDK version and capabilities. - * - * When a new bit is added, the following should be updated to provide - * access to the new capability: - * HS: JDK_Version class - * SDK: JDK_GetVersionInfo0 - * - * ========================================================================== - */ -typedef struct { - unsigned int jvm_version; /* Encoded $VNUM as defined by JEP-223 */ - unsigned int patch_version : 8; /* JEP-223 patch version */ - unsigned int reserved3 : 8; - unsigned int reserved1 : 16; - unsigned int reserved2; - - /* The following bits represents JVM supports that JDK has dependency on. - * JDK can use these bits to determine which JVM version - * and support it has to maintain runtime compatibility. - * - * When a new bit is added in a minor or update release, make sure - * the new bit is also added in the main/baseline. - */ - unsigned int is_attachable : 1; - unsigned int : 31; - unsigned int : 32; - unsigned int : 32; -} jvm_version_info; - -#define JVM_VERSION_MAJOR(version) ((version & 0xFF000000) >> 24) -#define JVM_VERSION_MINOR(version) ((version & 0x00FF0000) >> 16) -#define JVM_VERSION_SECURITY(version) ((version & 0x0000FF00) >> 8) -#define JVM_VERSION_BUILD(version) ((version & 0x000000FF)) - -JNIEXPORT void JNICALL -JVM_GetVersionInfo(JNIEnv* env, jvm_version_info* info, size_t info_size); - -typedef struct { - unsigned int jdk_version; /* Encoded $VNUM as defined by JEP-223 */ - unsigned int patch_version : 8; /* JEP-223 patch version */ - unsigned int reserved3 : 8; - unsigned int reserved1 : 16; - unsigned int reserved2; - - /* The following bits represents new JDK supports that VM has dependency on. - * VM implementation can use these bits to determine which JDK version - * and support it has to maintain runtime compatibility. - * - * When a new bit is added in a minor or update release, make sure - * the new bit is also added in the main/baseline. - */ - unsigned int thread_park_blocker : 1; - unsigned int post_vm_init_hook_enabled : 1; - unsigned int pending_list_uses_discovered_field : 1; - unsigned int : 29; - unsigned int : 32; - unsigned int : 32; -} jdk_version_info; - -#define JDK_VERSION_MAJOR(version) ((version & 0xFF000000) >> 24) -#define JDK_VERSION_MINOR(version) ((version & 0x00FF0000) >> 16) -#define JDK_VERSION_SECURITY(version) ((version & 0x0000FF00) >> 8) -#define JDK_VERSION_BUILD(version) ((version & 0x000000FF)) - -/* - * This is the function JDK_GetVersionInfo0 defined in libjava.so - * that is dynamically looked up by JVM. - */ -typedef void (*jdk_version_info_fn_t)(jdk_version_info* info, size_t info_size); - -/* - * This structure is used by the launcher to get the default thread - * stack size from the VM using JNI_GetDefaultJavaVMInitArgs() with a - * version of 1.1. As it is not supported otherwise, it has been removed - * from jni.h - */ -typedef struct JDK1_1InitArgs { - jint version; - - char **properties; - jint checkSource; - jint nativeStackSize; - jint javaStackSize; - jint minHeapSize; - jint maxHeapSize; - jint verifyMode; - char *classpath; - - jint (JNICALL *vfprintf)(FILE *fp, const char *format, va_list args); - void (JNICALL *exit)(jint code); - void (JNICALL *abort)(void); - - jint enableClassGC; - jint enableVerboseGC; - jint disableAsyncGC; - jint verbose; - jboolean debugging; - jint debugPort; -} JDK1_1InitArgs; - -#ifdef __cplusplus -} /* extern "C" */ -#endif /* __cplusplus */ - -#endif /* !_JAVASOFT_JVM_H_ */ - -#endif // SHARE_VM_PRIMS_JVM_H --- old/src/java.base/macosx/native/include/jni_md.h 2017-10-25 08:27:06.258932452 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,42 +0,0 @@ -/* - * Copyright (c) 1996, 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. 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 _JAVASOFT_JNI_MD_H_ -#define _JAVASOFT_JNI_MD_H_ - -#define JNIEXPORT __attribute__((visibility("default"))) -#define JNIIMPORT __attribute__((visibility("default"))) -#define JNICALL - -typedef int jint; -#ifdef _LP64 /* 64-bit */ -typedef long jlong; -#else -typedef long long jlong; -#endif - -typedef signed char jbyte; - -#endif /* !_JAVASOFT_JNI_MD_H_ */ --- old/src/java.base/macosx/native/include/jvm_md.h 2017-10-25 08:27:10.298003222 -0400 +++ /dev/null 2017-08-03 13:42:08.516000218 -0400 @@ -1,80 +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. 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 _JAVASOFT_JVM_MD_H_ -#define _JAVASOFT_JVM_MD_H_ - -/* - * This file is currently collecting system-specific dregs for the - * JNI conversion, which should be sorted out later. - */ - -#include /* For DIR */ -#include /* For MAXPATHLEN */ -#include /* For F_OK, R_OK, W_OK */ -#include /* For ptrdiff_t */ -#include /* For uintptr_t */ - -#define JNI_ONLOAD_SYMBOLS {"JNI_OnLoad"} -#define JNI_ONUNLOAD_SYMBOLS {"JNI_OnUnload"} - -#define JNI_LIB_PREFIX "lib" -#define JNI_LIB_SUFFIX ".dylib" -#define VERSIONED_JNI_LIB_NAME(NAME, VERSION) JNI_LIB_PREFIX NAME "." VERSION JNI_LIB_SUFFIX -#define JNI_LIB_NAME(NAME) JNI_LIB_PREFIX NAME JNI_LIB_SUFFIX - -#define JVM_MAXPATHLEN MAXPATHLEN - -#define JVM_R_OK R_OK -#define JVM_W_OK W_OK -#define JVM_X_OK X_OK -#define JVM_F_OK F_OK - -/* - * File I/O - */ - -#include -#include -#include -#include -#include - -/* O Flags */ - -#define JVM_O_RDONLY O_RDONLY -#define JVM_O_WRONLY O_WRONLY -#define JVM_O_RDWR O_RDWR -#define JVM_O_O_APPEND O_APPEND -#define JVM_O_EXCL O_EXCL -#define JVM_O_CREAT O_CREAT - -/* Signals */ - -#define JVM_SIGINT SIGINT -#define JVM_SIGTERM SIGTERM - - -#endif /* !_JAVASOFT_JVM_MD_H_ */