diff -urp webkitgtk-2.49.90.epoxy/Source/JavaScriptCore/runtime/MathCommon.cpp webkitgtk-2.49.90/Source/JavaScriptCore/runtime/MathCommon.cpp
--- webkitgtk-2.49.90.epoxy/Source/JavaScriptCore/runtime/MathCommon.cpp	2025-09-10 10:41:48.898658787 -0500
+++ webkitgtk-2.49.90/Source/JavaScriptCore/runtime/MathCommon.cpp	2025-09-10 10:43:01.379478824 -0500
@@ -626,11 +626,6 @@ static inline double roundeven(double op
 }
 #endif
 
-JSC_DEFINE_NOEXCEPT_JIT_OPERATION(f32_roundeven, float, (float operand)) { return roundevenf(operand); }
-JSC_DEFINE_NOEXCEPT_JIT_OPERATION(f64_roundeven, double, (double operand)) { return roundeven(operand); }
-JSC_DEFINE_NOEXCEPT_JIT_OPERATION(f32_trunc, float, (float operand)) { return std::trunc(operand); }
-JSC_DEFINE_NOEXCEPT_JIT_OPERATION(f64_trunc, double, (double operand)) { return std::trunc(operand); }
-
 JSC_DEFINE_NOEXCEPT_JIT_OPERATION(i32_div_s, int32_t, (int32_t a, int32_t b)) { return a / b; }
 JSC_DEFINE_NOEXCEPT_JIT_OPERATION(i32_div_u, uint32_t, (uint32_t a, uint32_t b)) { return a / b; }
 JSC_DEFINE_NOEXCEPT_JIT_OPERATION(i32_rem_s, int32_t, (int32_t a, int32_t b)) { return a % b; }
diff -urp webkitgtk-2.49.90.epoxy/Source/JavaScriptCore/runtime/MathCommon.h webkitgtk-2.49.90/Source/JavaScriptCore/runtime/MathCommon.h
--- webkitgtk-2.49.90.epoxy/Source/JavaScriptCore/runtime/MathCommon.h	2025-09-10 10:41:48.900020177 -0500
+++ webkitgtk-2.49.90/Source/JavaScriptCore/runtime/MathCommon.h	2025-09-10 10:43:01.381897008 -0500
@@ -368,10 +368,6 @@ JSC_DECLARE_NOEXCEPT_JIT_OPERATION(round
 
 JSC_DECLARE_NOEXCEPT_JIT_OPERATION(f32_nearest, float, (float));
 JSC_DECLARE_NOEXCEPT_JIT_OPERATION(f64_nearest, double, (double));
-JSC_DECLARE_NOEXCEPT_JIT_OPERATION(f32_roundeven, float, (float));
-JSC_DECLARE_NOEXCEPT_JIT_OPERATION(f64_roundeven, double, (double));
-JSC_DECLARE_NOEXCEPT_JIT_OPERATION(f32_trunc, float, (float));
-JSC_DECLARE_NOEXCEPT_JIT_OPERATION(f64_trunc, double, (double));
 
 JSC_DECLARE_NOEXCEPT_JIT_OPERATION(i32_div_s, int32_t, (int32_t, int32_t));
 JSC_DECLARE_NOEXCEPT_JIT_OPERATION(i32_div_u, uint32_t, (uint32_t, uint32_t));
diff -urp webkitgtk-2.49.90.epoxy/Source/JavaScriptCore/wasm/WasmOMGIRGenerator32_64.cpp webkitgtk-2.49.90/Source/JavaScriptCore/wasm/WasmOMGIRGenerator32_64.cpp
--- webkitgtk-2.49.90.epoxy/Source/JavaScriptCore/wasm/WasmOMGIRGenerator32_64.cpp	2025-08-08 04:59:15.086427500 -0500
+++ webkitgtk-2.49.90/Source/JavaScriptCore/wasm/WasmOMGIRGenerator32_64.cpp	2025-09-10 11:18:50.676573218 -0500
@@ -6371,18 +6371,26 @@ auto OMGIRGenerator::addF32ConvertUI64(E
 auto OMGIRGenerator::addF64Nearest(ExpressionType argVar, ExpressionType& result) -> PartialResult
 {
     Value* arg = get(argVar);
-    Value* callee = m_currentBlock->appendNew<ConstPtrValue>(m_proc, origin(), tagCFunction<OperationPtrTag>(Math::f64_roundeven));
-    Value* call = m_currentBlock->appendNew<CCallValue>(m_proc, B3::Double, origin(), callee, arg);
-    result = push(call);
+    PatchpointValue* patchpoint = m_currentBlock->appendNew<PatchpointValue>(m_proc, Double, origin());
+    patchpoint->append(arg, ValueRep::SomeRegister);
+    patchpoint->setGenerator([=] (CCallHelpers& jit, const StackmapGenerationParams& params) {
+        jit.roundTowardNearestIntDouble(params[1].fpr(), params[0].fpr());
+    });
+    patchpoint->effects = Effects::none();
+    result = push(patchpoint);
     return { };
 }
 
 auto OMGIRGenerator::addF32Nearest(ExpressionType argVar, ExpressionType& result) -> PartialResult
 {
     Value* arg = get(argVar);
-    Value* callee = m_currentBlock->appendNew<ConstPtrValue>(m_proc, origin(), tagCFunction<OperationPtrTag>(Math::f32_roundeven));
-    Value* call = m_currentBlock->appendNew<CCallValue>(m_proc, B3::Float, origin(), callee, arg);
-    result = push(call);
+    PatchpointValue* patchpoint = m_currentBlock->appendNew<PatchpointValue>(m_proc, Float, origin());
+    patchpoint->append(arg, ValueRep::SomeRegister);
+    patchpoint->setGenerator([=] (CCallHelpers& jit, const StackmapGenerationParams& params) {
+        jit.roundTowardNearestIntFloat(params[1].fpr(), params[0].fpr());
+    });
+    patchpoint->effects = Effects::none();
+    result = push(patchpoint);
     return { };
 }
 
