Skip to content

Commit

Permalink
openjdk17: update to 17.0.9+9
Browse files Browse the repository at this point in the history
  • Loading branch information
hadfl committed Dec 1, 2023
1 parent c2d39f0 commit 77bd59f
Show file tree
Hide file tree
Showing 21 changed files with 306 additions and 283 deletions.
2 changes: 1 addition & 1 deletion build/openjdk17/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
. ../../lib/build.sh

PROG=openjdk
VER=17.0.8.1+1
VER=17.0.9+9
PKG=runtime/java/openjdk17
SUMMARY="openjdk ${VER%%.*}"
DESC="Open-source implementation of the seventeenth edition of the "
Expand Down
70 changes: 70 additions & 0 deletions build/openjdk17/patches/README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,76 @@ Most patches -p0

JDK17:

17.0.9

Much rework around safefetch. Removed illumos-port-12.patch, and
removed the is_safefetch_fault() block entirely. (Looked at the
Windows port, and that block was removed there in this release. It
wasn't present at all in other platforms.) Copied the new assembler
src/hotspot/os_cpu/linux_x86/safefetch_linux_x86_64.S to
src/hotspot/os_cpu/solaris_x86/safefetch_solaris_x86_64.S, see
illumos-port-17.patch

In os_solaris_x86.cpp, the end of print_context() is now split off
into print_tos_pc()

We need an implementation of os::can_trim_native_heap() and
trim_native_heap(); simply add a stub in os_solaris.inline.hpp to
return false like pretty much every other platform except linux does.

17.0.8

Reinstate make/data/charsetmapping/stdcs-solaris, removal broke the
build.
See illumos-port-16.patch

Cleanup: remove TAR_CREATE_FILE_PARAM TAR_CREATE_EXTRA_PARAM

Cleanup: Removed another STLPORT reference

17.0.7

Minor patch noise. Removed an STLPORT patch.

17.0.6

Minor patch noise.

17.0.5

A number of functions centralised into os_posix

17.0.4

Build broken by https://www.illumos.org/issues/14418. That did 2
things - (1) exposed memcntl and meminfo by default, and (2) changed
the signature for memcntl from caddr_t to void so there's a
mismatch. The fix adopted is to modify the internal java signature for
memcntl to the new version, which still allows builds on older
releases as the old definition in sys/mman.h was effectively invisible
there.


Remove some unnecessary patches
src/java.base/unix/native/libjli/java_md.h
- new comment is good
src/java.desktop/unix/native/common/awt/fontpath.c
- shouldn't need to check for SunOS 5.8/5.9
Remove HS_DTRACE_WORKAROUND_TAIL_CALL_BUG, the bug it works around
was fixed in 2008
Remove remaining SUNPRO and related MLIB_NO_LIBSUNMATH checks
src/java.desktop/unix/native/common/awt/X11Color.c
- the complexity is over 20 years old and no longer relevant
make/autoconf/flags-cflags.m4
- adding -DTRIMMED is useless
src/java.desktop/unix/native/libawt_xawt/awt/awt_InputMethod.c
- unnecessary on illumos and current Solaris (and my S10 system too)
use the 64-bit rdtsc variant

17.0.2

illumos-port-15.patch to fix the broken ld check

17-35

RC1, no changes
Expand Down
6 changes: 3 additions & 3 deletions build/openjdk17/patches/illumos-port-1.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/src/hotspot/os/solaris/os_solaris.cpp Thu May 28 11:43:31 2020
+++ b/src/hotspot/os/solaris/os_solaris.cpp Thu May 28 13:53:16 2020
@@ -2785,52 +2785,35 @@
@@ -2751,52 +2751,35 @@
bool os::Solaris::_synchronization_initialized;

void os::Solaris::synchronization_init() {
Expand Down Expand Up @@ -78,7 +78,7 @@
}
_synchronization_initialized = true;
}
@@ -3634,9 +3616,6 @@
@@ -3581,9 +3563,6 @@
// 3. Tx resumes from park


Expand All @@ -88,7 +88,7 @@
// utility to compute the abstime argument to timedwait.
// TODO-FIXME: switch from compute_abstime() to unpackTime().

@@ -3650,24 +3629,8 @@
@@ -3597,24 +3576,8 @@
jlong seconds = millis / 1000;
jlong max_wait_period;

Expand Down
35 changes: 0 additions & 35 deletions build/openjdk17/patches/illumos-port-12.patch

This file was deleted.

4 changes: 2 additions & 2 deletions build/openjdk17/patches/illumos-port-13.patch
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ diff --git a/src/hotspot/os/solaris/os_solaris.cpp b/src/hotspot/os/solaris/os_s
index 894958e7c..5273ea961 100644
--- a/src/hotspot/os/solaris/os_solaris.cpp
+++ b/src/hotspot/os/solaris/os_solaris.cpp
@@ -1592,37 +1592,6 @@ void os::print_jni_name_suffix_on(outputStream* st, int args_size) {
@@ -1584,37 +1584,6 @@ void os::print_jni_name_suffix_on(outputStream* st, int args_size) {
// no suffix required
}

Expand Down Expand Up @@ -56,7 +56,7 @@ index 894958e7c..5273ea961 100644
////////////////////////////////////////////////////////////////////////////////
// Virtual Memory

@@ -2909,7 +2909,6 @@ jint os::init_2(void) {
@@ -2906,7 +2875,6 @@ jint os::init_2(void) {
FLAG_SET_ERGO_IF_DEFAULT(UseNUMAInterleaving, true);
}

Expand Down
2 changes: 1 addition & 1 deletion build/openjdk17/patches/illumos-port-14.patch
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ diff --git a/src/hotspot/os_cpu/solaris_x86/os_solaris_x86.cpp b/src/hotspot/os_
index c5a72c791..9d9ab5618 100644
--- a/src/hotspot/os_cpu/solaris_x86/os_solaris_x86.cpp
+++ b/src/hotspot/os_cpu/solaris_x86/os_solaris_x86.cpp
@@ -382,8 +382,11 @@ bool PosixSignals::pd_hotspot_signal_handler(int sig, siginfo_t* info,
@@ -377,8 +377,11 @@ bool PosixSignals::pd_hotspot_signal_handler(int sig, siginfo_t* info,
// Handle ALL stack overflow variations here
if (sig == SIGSEGV && info->si_code == SEGV_ACCERR) {
address addr = (address) info->si_addr;
Expand Down
15 changes: 15 additions & 0 deletions build/openjdk17/patches/illumos-port-15.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
--- a/make/autoconf/toolchain.m4 Sat Jul 3 15:56:43 2021
+++ b/make/autoconf/toolchain.m4 Sat Jul 3 16:11:51 2021
@@ -228,7 +228,11 @@
# Linux x86_64 needs higher binutils after 8265783
# (this really is a dependency on as version, but we take ld as a check for a general binutils version)
if test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
- TOOLCHAIN_MINIMUM_LD_VERSION_gcc="2.25"
+ if test "x$OPENJDK_TARGET_OS" = xsolaris; then
+ TOOLCHAIN_MINIMUM_LD_VERSION_gcc=""
+ else
+ TOOLCHAIN_MINIMUM_LD_VERSION_gcc="2.25"
+ fi
fi

# Use indirect variable referencing
28 changes: 28 additions & 0 deletions build/openjdk17/patches/illumos-port-16.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
--- /dev/null Sat Mar 4 12:15:07 2023
+++ a/make/data/charsetmapping/stdcs-solaris Sat Mar 4 12:03:56 2023
@@ -0,0 +1,25 @@
+#
+# generate these charsets into sun.nio.cs
+#
+Big5
+Big5_Solaris
+Big5_HKSCS # always together with Big5
+EUC_CN
+EUC_KR
+EUC_JP
+EUC_JP_LINUX
+EUC_JP_Open
+EUC_TW
+GBK
+ISO_8859_11
+ISO_8859_3
+ISO_8859_6
+ISO_8859_8
+Johab
+PCK
+TIS_620
+JIS_X_0201
+JIS_X_0208
+JIS_X_0212
+JIS_X_0208_Solaris
+JIS_X_0212_Solaris
63 changes: 63 additions & 0 deletions build/openjdk17/patches/illumos-port-17.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
Copied verbatim from the linux_x86 version

--- /dev/null Thu Oct 19 11:20:19 2023
+++ b/src/hotspot/os_cpu/solaris_x86/safefetch_solaris_x86_64.S Thu Oct 19 11:02:38 2023
@@ -0,0 +1,58 @@
+#
+# Copyright (c) 2022 SAP SE. All rights reserved.
+# Copyright (c) 2022, Oracle and/or its affiliates. All rights reserved.
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# This code is free software; you can redistribute 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.
+#
+ .globl SafeFetch32_impl
+ .globl SafeFetchN_impl
+ .globl _SafeFetch32_fault
+ .globl _SafeFetchN_fault
+ .globl _SafeFetch32_continuation
+ .globl _SafeFetchN_continuation
+
+ .text
+
+
+ # Support for int SafeFetch32(int* address, int defaultval);
+ #
+ # %rdi : address
+ # %esi : defaultval
+ .type SafeFetch32_impl,@function
+SafeFetch32_impl:
+_SafeFetch32_fault:
+ movl (%rdi), %eax # load target value, may fault
+ ret
+_SafeFetch32_continuation:
+ movl %esi, %eax # return default
+ ret
+
+ # Support for intptr_t SafeFetchN(intptr_t* address, intptr_t defaultval);
+ #
+ # %rdi : address
+ # %rsi : defaultval
+ .type SafeFetchN_impl,@function
+SafeFetchN_impl:
+_SafeFetchN_fault:
+ movq (%rdi), %rax # load target value, may fault
+ ret
+_SafeFetchN_continuation:
+ movq %rsi, %rax # return default
+ ret
4 changes: 2 additions & 2 deletions build/openjdk17/patches/illumos-port-6.patch
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ It "fixes" AIX because that's using the xlc toolchain.

--- a/src/hotspot/share/runtime/os.cpp Wed Aug 12 16:38:30 2020
+++ b/src/hotspot/share/runtime/os.cpp Thu Aug 13 19:44:36 2020
@@ -155,7 +155,7 @@
@@ -148,7 +148,7 @@
// No offset when dealing with UTC
time_t UTC_to_local = 0;
if (!utc) {
Expand All @@ -15,7 +15,7 @@ It "fixes" AIX because that's using the xlc toolchain.
UTC_to_local = -(time_struct.tm_gmtoff);
#elif defined(_WINDOWS)
long zone;
@@ -166,7 +166,7 @@
@@ -159,7 +159,7 @@
#endif

// tm_gmtoff already includes adjustment for daylight saving
Expand Down
2 changes: 1 addition & 1 deletion build/openjdk17/patches/illumos-port-7.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/src/hotspot/share/prims/methodHandles.cpp Wed Aug 19 21:41:08 2020
+++ b/src/hotspot/share/prims/methodHandles.cpp Fri Aug 21 10:42:08 2020
@@ -1528,6 +1528,10 @@
@@ -1532,6 +1532,10 @@
#define LANG "Ljava/lang/"
#define JLINV "Ljava/lang/invoke/"

Expand Down
2 changes: 1 addition & 1 deletion build/openjdk17/patches/illumos-port-8.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/src/hotspot/os/posix/os_posix.cpp Fri Oct 16 12:10:19 2020
+++ b/src/hotspot/os/posix/os_posix.cpp Fri Oct 16 12:11:19 2020
@@ -1102,7 +1102,7 @@
@@ -1190,7 +1190,7 @@
"enabled executable stack (see man page execstack(8))");

} else {
Expand Down
2 changes: 1 addition & 1 deletion build/openjdk17/patches/illumos-port-9.patch
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
}

frame os::get_sender_for_C_frame(frame* fr) {
@@ -464,39 +434,8 @@
@@ -459,39 +429,8 @@
// Handle ALL stack overflow variations here
if (sig == SIGSEGV && info->si_code == SEGV_ACCERR) {
address addr = (address) info->si_addr;
Expand Down
2 changes: 1 addition & 1 deletion build/openjdk17/patches/illumos-signal-1.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/src/hotspot/os/posix/signals_posix.cpp Wed Oct 7 17:21:51 2020
+++ b/src/hotspot/os/posix/signals_posix.cpp Sat Oct 10 16:46:21 2020
@@ -552,6 +552,8 @@
@@ -546,6 +546,8 @@
#define JVM_HANDLE_XXX_SIGNAL JVM_handle_aix_signal
#elif defined(LINUX)
#define JVM_HANDLE_XXX_SIGNAL JVM_handle_linux_signal
Expand Down
4 changes: 2 additions & 2 deletions build/openjdk17/patches/illumos-signal-2.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/src/hotspot/os_cpu/solaris_x86/os_solaris_x86.cpp Sat Oct 10 19:55:00 2020
+++ b/src/hotspot/os_cpu/solaris_x86/os_solaris_x86.cpp Sat Oct 10 20:28:45 2020
@@ -687,7 +687,12 @@
@@ -682,7 +682,12 @@
return false;
}

Expand All @@ -14,7 +14,7 @@
struct sigaction oldAct;
sigaction(sig, (struct sigaction *)0, &oldAct);
if (oldAct.sa_sigaction != signalHandler) {
@@ -696,6 +701,7 @@
@@ -691,6 +696,7 @@
warning("Unexpected Signal %d occurred under user-defined signal handler %#lx", sig, (long)sighand);
}
}
Expand Down
2 changes: 1 addition & 1 deletion build/openjdk17/patches/illumos-signal-3.patch
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
if (info == NULL || info->si_code <= 0 || info->si_code == SI_NOINFO) {
// can't decode this kind of signal
info = NULL;
@@ -616,52 +564,6 @@
@@ -611,52 +559,6 @@
return true;
}

Expand Down
Loading

0 comments on commit 77bd59f

Please sign in to comment.