diff --git a/scripts/config.sh b/scripts/config.sh index a8ff987..083ed78 100644 --- a/scripts/config.sh +++ b/scripts/config.sh @@ -289,6 +289,33 @@ elif [ "$JDKVER" == "14" ]; then HOTSPOT_ABI=arm-sflt JNI_PATH_FLAGS="--with-jni-libpath=/usr/lib/$DEB_HOST_MULTIARCH/jni:/lib/$DEB_HOST_MULTIARCH:/usr/lib/$DEB_HOST_MULTIARCH:/usr/lib/jni:/lib:/usr/lib" +# OpenJDK 15 +elif [ "$JDKVER" == "15" ]; then + VERSION_POLICY="latest_general_availability" + JAVA_REPO="https://github.com/openjdk/jdk15u.git" + JAVA_SCM="git" + PATCHVER="jdk15" + AUTOGEN_STYLE="v2" + if [ "$BUILDER_TYPE" = "native" ]; then + HOSTJDK="$BUILDDIR/jdk-ev3" + HOSTJDK_RENAME_FROM="$BUILDDIR/jdk" + HOSTJDK_FILE="$BUILDDIR/jdk-ev3.tar.gz" + # stretch and buster have different versions + if [ "$BUILDER_DISTRO" = "stretch" ]; then + HOSTJDK_URL="https://ci.adoptopenjdk.net/job/eljbuild/job/stretch-14/lastSuccessfulBuild/artifact/build/jdk-ev3.tar.gz" + else + HOSTJDK_URL="https://ci.adoptopenjdk.net/job/eljbuild/job/buster-14/lastSuccessfulBuild/artifact/build/jdk-ev3.tar.gz" + fi + else + # same for both stretch & buster + HOSTJDK="$BUILDDIR/jdk-14.0.1+7" + HOSTJDK_FILE="$BUILDDIR/OpenJDK14U-jdk_x64_linux_hotspot_14.0.1_7.tar.gz" + HOSTJDK_URL="https://github.com/AdoptOpenJDK/openjdk14-binaries/releases/download/jdk-14.0.1%2B7/OpenJDK14U-jdk_x64_linux_hotspot_14.0.1_7.tar.gz" + fi + IMAGEDIR="$JDKDIR/build/linux-arm-${JDKVM}-${HOTSPOT_DEBUG}/images" + HOTSPOT_ABI=arm-sflt + JNI_PATH_FLAGS="--with-jni-libpath=/usr/lib/$DEB_HOST_MULTIARCH/jni:/lib/$DEB_HOST_MULTIARCH:/usr/lib/$DEB_HOST_MULTIARCH:/usr/lib/jni:/lib:/usr/lib" + # OpenJDK Loom & Master+dev elif [ "$JDKVER" == "loom" ] || [ "$JDKVER" == "tip" ]; then if [ "$JDKVER" == "loom" ]; then @@ -333,6 +360,7 @@ else echo "JDKVER=12" >&2 echo "JDKVER=13" >&2 echo "JDKVER=14" >&2 + echo "JDKVER=15" >&2 echo "JDKVER=loom" >&2 echo "JDKVER=tip" >&2 exit 1 diff --git a/scripts/jdk15_cds.patch b/scripts/jdk15_cds.patch index a3da679..2a036c4 100644 --- a/scripts/jdk15_cds.patch +++ b/scripts/jdk15_cds.patch @@ -1,8 +1,8 @@ diff --git a/src/hotspot/share/memory/metaspaceShared.cpp b/src/hotspot/share/memory/metaspaceShared.cpp -index 20d7f53d3..4f6130b62 100644 +index 57a97b5c2..448156667 100644 --- a/src/hotspot/share/memory/metaspaceShared.cpp +++ b/src/hotspot/share/memory/metaspaceShared.cpp -@@ -1221,7 +1221,7 @@ public: +@@ -1311,7 +1311,7 @@ public: address obj = ref->obj(); int bytes = ref->size() * BytesPerWord; char* p; @@ -11,7 +11,7 @@ index 20d7f53d3..4f6130b62 100644 char* oldtop; char* newtop; -@@ -1239,7 +1239,7 @@ public: +@@ -1329,7 +1329,7 @@ public: Klass* klass = (Klass*)obj; if (klass->is_instance_klass()) { SystemDictionaryShared::validate_before_archiving(InstanceKlass::cast(klass)); @@ -21,10 +21,10 @@ index 20d7f53d3..4f6130b62 100644 } p = _rw_region.allocate(bytes, alignment); diff --git a/src/hotspot/share/memory/metaspaceShared.hpp b/src/hotspot/share/memory/metaspaceShared.hpp -index 4a4ee709f..57af38f19 100644 +index 326522c4a..4c5e54b4d 100644 --- a/src/hotspot/share/memory/metaspaceShared.hpp +++ b/src/hotspot/share/memory/metaspaceShared.hpp -@@ -70,7 +70,7 @@ public: +@@ -71,7 +71,7 @@ public: DumpRegion(const char* name) : _name(name), _base(NULL), _top(NULL), _end(NULL), _is_packed(false) {} char* expand_top_to(char* newtop); diff --git a/scripts/jdk15_new.patch b/scripts/jdk15_new.patch index 5da62f7..3ff1f1b 100644 --- a/scripts/jdk15_new.patch +++ b/scripts/jdk15_new.patch @@ -1,8 +1,8 @@ diff --git a/make/autoconf/hotspot.m4 b/make/autoconf/hotspot.m4 -index 0e4f4c283..647f41158 100644 +index 43653c115..4c5f960a8 100644 --- a/make/autoconf/hotspot.m4 +++ b/make/autoconf/hotspot.m4 -@@ -172,6 +172,11 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_MISC], +@@ -138,6 +138,11 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_MISC], HOTSPOT_TARGET_CPU_DEFINE="ARM32" fi @@ -13,13 +13,13 @@ index 0e4f4c283..647f41158 100644 + # --with-cpu-port is no longer supported UTIL_DEPRECATED_ARG_WITH(with-cpu-port) - ]) + diff --git a/src/hotspot/share/memory/metaspaceShared.cpp b/src/hotspot/share/memory/metaspaceShared.cpp -index 5bc8df595..20d7f53d3 100644 +index 28742febe..57a97b5c2 100644 --- a/src/hotspot/share/memory/metaspaceShared.cpp +++ b/src/hotspot/share/memory/metaspaceShared.cpp -@@ -71,6 +71,7 @@ - #include "utilities/bitMap.inline.hpp" +@@ -72,6 +72,7 @@ + #include "utilities/ostream.hpp" #include "utilities/defaultStream.hpp" #include "utilities/hashtable.inline.hpp" +#include "gc/shared/softRefPolicy.hpp" @@ -27,10 +27,10 @@ index 5bc8df595..20d7f53d3 100644 #include "gc/g1/g1CollectedHeap.hpp" #endif diff --git a/src/hotspot/share/oops/constantPool.cpp b/src/hotspot/share/oops/constantPool.cpp -index b325f9f16..da47aff73 100644 +index d27bf3474..35bc24c7b 100644 --- a/src/hotspot/share/oops/constantPool.cpp +++ b/src/hotspot/share/oops/constantPool.cpp -@@ -429,8 +429,12 @@ void ConstantPool::remove_unshareable_info() { +@@ -437,8 +437,12 @@ void ConstantPool::remove_unshareable_info() { } int ConstantPool::cp_to_object_index(int cp_index) {