head 1.2; access; symbols; locks; strict; comment @// @; 1.2 date 2025.08.06.13.42.45; author pho; state dead; branches; next 1.1; commitid Zod5d4bBFP1rQF5G; 1.1 date 2025.08.04.13.22.06; author pho; state Exp; branches; next ; commitid hLvjvkVJi5XjNp5G; desc @@ 1.2 log @lang/openjdk11: Reduce the number of patches by making use of SUBST, like I did in openjdk17 @ text @$NetBSD: patch-src_hotspot_share_interpreter_interpreterRuntime.cpp,v 1.1 2025/08/04 13:22:06 pho Exp $ Workaround for the Hotspot VM dying on Apple Silicon chips. See the patch to threadWXSetters.inline.hpp for details. --- src/hotspot/share/interpreter/interpreterRuntime.cpp.orig 2025-08-01 08:05:13.541716842 +0000 +++ src/hotspot/share/interpreter/interpreterRuntime.cpp @@@@ -1007,7 +1007,7 @@@@ IRT_END nmethod* InterpreterRuntime::frequency_counter_overflow(JavaThread* thread, address branch_bcp) { // Enable WXWrite: the function is called directly by interpreter. - MACOS_AARCH64_ONLY(ThreadWXEnable wx(WXWrite, thread)); + AARCH64_ONLY(ThreadWXEnable wx(WXWrite, thread)); nmethod* nm = frequency_counter_overflow_inner(thread, branch_bcp); assert(branch_bcp != NULL || nm == NULL, "always returns null for non OSR requests"); @ 1.1 log @lang/openjdk11: Workaround for the VM dying on Apple Silicon chips See the patch for threadWXSetters.inline.hpp for details. I rebuilt the bootkit for aarch64 with new patches applied. This may cause some performance regression on Cortex series, but as I stated in the patch comment, relying on assumptions made on implementation details of chips is fundamentally unsound, and that's why it didn't work on Apple Silicon in the first place. Also backported fixes regarding floating point arithmetics that appeared in OpenJDK 22. @ text @d1 1 a1 1 $NetBSD$ @