diff --git a/fix-wasm.patch b/fix-wasm.patch new file mode 100644 index 0000000..386ea63 --- /dev/null +++ b/fix-wasm.patch @@ -0,0 +1,48 @@ +From 9140ce712aa87091613874d802787ab476be0e39 Mon Sep 17 00:00:00 2001 +From: Michael Catanzaro +Date: Wed, 14 Aug 2024 14:58:05 -0500 +Subject: [PATCH] Revert "Cherry-pick 272448.770@safari-7618-branch + (6d311cd7fefc). https://bugs.webkit.org/show_bug.cgi?id=271175" + https://bugs.webkit.org/show_bug.cgi?id=278113 + +This reverts commit 279c9d7963182cc35cf4e0bfebe87df2d83eaef8. + +This broke wasm, and I don't know how to fix it. + +Canonical link: https://commits.webkit.org/274313.373@webkitglib/2.44 +--- + .../stress/many-calls-results-on-stack.js | 39 ------------------- + Source/JavaScriptCore/wasm/WasmBBQJIT.cpp | 19 --------- + 2 files changed, 58 deletions(-) + delete mode 100644 JSTests/wasm/stress/many-calls-results-on-stack.js + +diff --git a/Source/JavaScriptCore/wasm/WasmBBQJIT.cpp b/Source/JavaScriptCore/wasm/WasmBBQJIT.cpp +index 9049865e8ce7..3f142cf5e90f 100644 +--- a/Source/JavaScriptCore/wasm/WasmBBQJIT.cpp ++++ b/Source/JavaScriptCore/wasm/WasmBBQJIT.cpp +@@ -3958,25 +3958,6 @@ void BBQJIT::returnValuesFromCall(Vector& results, const FunctionSigna + ASSERT(m_validFPRs.contains(returnLocation.asFPR(), Width::Width128)); + m_fprSet.add(returnLocation.asFPR(), Width::Width128); + } +- } else { +- ASSERT(returnLocation.isStackArgument()); +- // FIXME: Ideally, we would leave these values where they are but a subsequent call could clobber them before they are used. +- // That said, stack results are very rare so this isn't too painful. +- // Even if we did leave them where they are, we'd need to flush them to their canonical location at the next branch otherwise +- // we could have something like (assume no result regs for simplicity): +- // call (result i32 i32) $foo +- // if (result i32) // Stack: i32(StackArgument:8) i32(StackArgument:0) +- // // Stack: i32(StackArgument:8) +- // else +- // call (result i32 i32) $bar // Stack: i32(StackArgument:8) we have to flush the stack argument to make room for the result of bar +- // drop // Stack: i32(Stack:X) i32(StackArgument:8) i32(StackArgument:0) +- // drop // Stack: i32(Stack:X) i32(StackArgument:8) +- // end +- // return // Stack i32(*Conflicting locations*) +- +- Location canonicalLocation = canonicalSlot(result); +- emitMoveMemory(result.type(), returnLocation, canonicalLocation); +- returnLocation = canonicalLocation; + } + } + bind(result, returnLocation); diff --git a/webkit2gtk3.spec b/webkit2gtk3.spec index 2e8ab55..07980bd 100644 --- a/webkit2gtk3.spec +++ b/webkit2gtk3.spec @@ -12,7 +12,7 @@ Name: webkit2gtk3 Version: 2.44.3 -Release: 1%{?dist} +Release: 2%{?dist} Summary: GTK Web content engine library License: LGPLv2 @@ -24,6 +24,9 @@ Source1: https://webkitgtk.org/releases/webkitgtk-%{version}.tar.xz.asc # $ gpg --export --export-options export-minimal 013A0127AC9C65B34FFA62526C1009B693975393 5AA3BC334FD7E3369E7C77B291C559DBE4C9123B > webkitgtk-keys.gpg Source2: webkitgtk-keys.gpg +# https://bugs.webkit.org/show_bug.cgi?id=278113 +Patch0: fix-wasm.patch + BuildRequires: bison BuildRequires: bubblewrap BuildRequires: cmake @@ -294,6 +297,10 @@ export NINJA_STATUS="[%f/%t][%e] " %{_datadir}/gir-1.0/JavaScriptCore-4.0.gir %changelog +* Thu Aug 15 2024 Michael Catanzaro - 2.44.3-2 +- Add patch to fix WebAssembly + Resolves: RHEL-32578 + * Tue Aug 13 2024 Michael Catanzaro - 2.44.3-1 - Update to 2.44.3 Resolves: RHEL-32578