diff --git a/SPECS/qt6-qtgraphs/qt6-qtgraphs.spec b/SPECS/qt6-qtgraphs/qt6-qtgraphs.spec index 0c1187046b..253b627336 100644 --- a/SPECS/qt6-qtgraphs/qt6-qtgraphs.spec +++ b/SPECS/qt6-qtgraphs/qt6-qtgraphs.spec @@ -6,17 +6,17 @@ # SPDX-License-Identifier: MulanPSL-2.0 %define qt_module qtgraphs -%define real_version 6.10.1 -%define short_version 6.10 +%define real_version 6.11.1 +%define short_version 6.11 Name: qt6-qtgraphs -Version: 6.10.1 +Version: 6.11.1 Release: %autorelease Summary: The Qt Graphs module enables you to visualize data in 3D License: BSD-3-Clause AND GFDL-1.3-no-invariants-only AND GPL-3.0-only URL: https://doc.qt.io/qt-6/qtgraphs-index.html VCS: git:https://code.qt.io/qt/qtgraphs.git -#!RemoteAsset: sha256:4d4fa0b21fa3c6b72ad5056e2a06e96e4bfda651e0a824d1f8e896c9ce5e576e +#!RemoteAsset: sha256:84b1138ab68a8e2956439895a4b85eb68dda48ac169da673f67191873b1e0462 Source0: https://download.qt.io/official_releases/qt/%{short_version}/%{real_version}/submodules/%{qt_module}-everywhere-src-%{real_version}.tar.xz BuildSystem: cmake diff --git a/SPECS/qt6-qtmultimedia/qt6-qtmultimedia.spec b/SPECS/qt6-qtmultimedia/qt6-qtmultimedia.spec index 05a06c4c51..40e803c9bf 100644 --- a/SPECS/qt6-qtmultimedia/qt6-qtmultimedia.spec +++ b/SPECS/qt6-qtmultimedia/qt6-qtmultimedia.spec @@ -6,19 +6,19 @@ # SPDX-License-Identifier: MulanPSL-2.0 %define qt_module qtmultimedia -%define real_version 6.10.1 -%define short_version 6.10 +%define real_version 6.11.1 +%define short_version 6.11 %bcond ffmpeg 0 Name: qt6-qtmultimedia -Version: 6.10.1 +Version: 6.11.1 Release: %autorelease Summary: Qt6 - Multimedia support License: LGPL-3.0-only OR GPL-3.0-only WITH Qt-GPL-exception-1.0 URL: https://www.qt.io VCS: git:https://code.qt.io/qt/qtmultimedia.git -#!RemoteAsset: sha256:f7a4f9bc2840d4f0f9f7329f0dcb3d3500c54177b8e368091a3727c7320e67b8 +#!RemoteAsset: sha256:390f8e52ddee3aca5c4de7eead900c84c4fa61ff6d1f0ebea9c7543365c09b0a Source0: https://download.qt.io/official_releases/qt/%{short_version}/%{real_version}/submodules/%{qt_module}-everywhere-src-%{real_version}.tar.xz BuildSystem: cmake diff --git a/SPECS/qt6-qtquick3dphysics/qt6-qtquick3dphysics.spec b/SPECS/qt6-qtquick3dphysics/qt6-qtquick3dphysics.spec index b927456543..eb0ec99bf6 100644 --- a/SPECS/qt6-qtquick3dphysics/qt6-qtquick3dphysics.spec +++ b/SPECS/qt6-qtquick3dphysics/qt6-qtquick3dphysics.spec @@ -6,17 +6,17 @@ # SPDX-License-Identifier: MulanPSL-2.0 %define qt_module qtquick3dphysics -%define real_version 6.10.1 -%define short_version 6.10 +%define real_version 6.11.1 +%define short_version 6.11 Name: qt6-qtquick3dphysics -Version: 6.10.1 +Version: 6.11.1 Release: %autorelease Summary: Qt6 - Quick3D Physics Libraries and utilities License: GPL-3.0-only WITH Qt-GPL-exception-1.0 URL: https://www.qt.io VCS: git:https://github.com/qt/qtquick3dphysics -#!RemoteAsset: sha256:d973847df1be6ee711e771df923537fb62fcac5bf57100f2ebc6f7742c8d2fee +#!RemoteAsset: sha256:d1086d6f014e7b698945cf0ee1dc3e43545ed7dcf0b5e501c0d6836a96ac79af Source0: https://download.qt.io/official_releases/qt/%{short_version}/%{real_version}/submodules/%{qt_module}-everywhere-src-%{real_version}.tar.xz BuildSystem: cmake diff --git a/SPECS/qt6-qtquickeffectmaker/qt6-qtquickeffectmaker.spec b/SPECS/qt6-qtquickeffectmaker/qt6-qtquickeffectmaker.spec index bd9cd850f8..c97d6cbace 100644 --- a/SPECS/qt6-qtquickeffectmaker/qt6-qtquickeffectmaker.spec +++ b/SPECS/qt6-qtquickeffectmaker/qt6-qtquickeffectmaker.spec @@ -6,17 +6,17 @@ # SPDX-License-Identifier: MulanPSL-2.0 %define qt_module qtquickeffectmaker -%define real_version 6.10.1 -%define short_version 6.10 +%define real_version 6.11.1 +%define short_version 6.11 Name: qt6-qtquickeffectmaker -Version: 6.10.1 +Version: 6.11.1 Release: %autorelease Summary: Tool for creating shader effects for Qt Quick License: GPL-3.0-only URL: https://doc.qt.io/qt-6/qtquickeffectmaker-index.html VCS: git:https://github.com/qt/qtquickeffectmaker -#!RemoteAsset: sha256:3036984cc55054f59c4a7c7d30d9b9a2dd7491344b3201c5a133cc3cdf12acc9 +#!RemoteAsset: sha256:cfe63e70e88bdd126a175762d3eeb38eb336e45beceedcbd027bc5362744136b Source0: https://download.qt.io/official_releases/qt/%{short_version}/%{real_version}/submodules/%{qt_module}-everywhere-src-%{real_version}.tar.xz Source1: quickeffectmaker.desktop BuildSystem: cmake diff --git a/SPECS/qt6-qtwebengine/0001-qtwebengine-SIOCGSTAMP.patch b/SPECS/qt6-qtwebengine/0001-qtwebengine-SIOCGSTAMP.patch deleted file mode 100644 index d97da42704..0000000000 --- a/SPECS/qt6-qtwebengine/0001-qtwebengine-SIOCGSTAMP.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/src/3rdparty/chromium/third_party/webrtc/rtc_base/physical_socket_server.cc b/src/3rdparty/chromium/third_party/webrtc/rtc_base/physical_socket_server.cc -index d421682..ffa75a7 100644 ---- a/src/3rdparty/chromium/third_party/webrtc/rtc_base/physical_socket_server.cc -+++ b/src/3rdparty/chromium/third_party/webrtc/rtc_base/physical_socket_server.cc -@@ -77,6 +77,11 @@ typedef void* SockOptArg; - - #if defined(WEBRTC_POSIX) && !defined(WEBRTC_MAC) && !defined(__native_client__) - -+// Seems that kernel 5.2.0 renames this define to SIOCGSTAMP_OLD -+#ifndef SIOCGSTAMP -+#define SIOCGSTAMP 0x8906 /* Get stamp (timeval) */ -+#endif -+ - int64_t GetSocketRecvTimestamp(int socket) { - struct timeval tv_ioctl; - int ret = ioctl(socket, SIOCGSTAMP, &tv_ioctl); diff --git a/SPECS/qt6-qtwebengine/0002-qtwebengine-link-pipewire.patch b/SPECS/qt6-qtwebengine/0001-qtwebengine-link-pipewire.patch similarity index 88% rename from SPECS/qt6-qtwebengine/0002-qtwebengine-link-pipewire.patch rename to SPECS/qt6-qtwebengine/0001-qtwebengine-link-pipewire.patch index 49d8aa2060..97300ce154 100644 --- a/SPECS/qt6-qtwebengine/0002-qtwebengine-link-pipewire.patch +++ b/SPECS/qt6-qtwebengine/0001-qtwebengine-link-pipewire.patch @@ -1,8 +1,7 @@ diff --git a/src/3rdparty/chromium/third_party/webrtc/webrtc.gni b/src/3rdparty/chromium/third_party/webrtc/webrtc.gni -index 5a1c43c..82870d2 100644 --- a/src/3rdparty/chromium/third_party/webrtc/webrtc.gni +++ b/src/3rdparty/chromium/third_party/webrtc/webrtc.gni -@@ -150,7 +150,7 @@ declare_args() { +@@ -144,7 +144,7 @@ rtc_use_pipewire = is_linux && use_sysroot # Set this to link PipeWire and required libraries directly instead of using the dlopen. diff --git a/SPECS/qt6-qtwebengine/0004-riscv-sandbox.patch b/SPECS/qt6-qtwebengine/0002-riscv-sandbox.patch similarity index 89% rename from SPECS/qt6-qtwebengine/0004-riscv-sandbox.patch rename to SPECS/qt6-qtwebengine/0002-riscv-sandbox.patch index c501859df0..5e1c7d5627 100644 --- a/SPECS/qt6-qtwebengine/0004-riscv-sandbox.patch +++ b/SPECS/qt6-qtwebengine/0002-riscv-sandbox.patch @@ -1,22 +1,17 @@ diff --git a/src/3rdparty/chromium/sandbox/features.gni b/src/3rdparty/chromium/sandbox/features.gni -index 8434144118..8aa52983f7 100644 --- a/src/3rdparty/chromium/sandbox/features.gni +++ b/src/3rdparty/chromium/sandbox/features.gni -@@ -9,7 +9,8 @@ +@@ -9,4 +9,5 @@ use_seccomp_bpf = (is_linux || is_chromeos || is_android) && (current_cpu == "x86" || current_cpu == "x64" || current_cpu == "arm" || current_cpu == "arm64" || - current_cpu == "mipsel" || current_cpu == "mips64el") + current_cpu == "mipsel" || current_cpu == "mips64el" || + current_cpu == "riscv64") - - # SSBD (Speculative Store Bypass Disable) is a mitigation of Spectre Variant 4. - # As Spectre Variant 4 can be mitigated by site isolation, opt-out SSBD on site diff --git a/src/3rdparty/chromium/sandbox/linux/BUILD.gn b/src/3rdparty/chromium/sandbox/linux/BUILD.gn -index 97e3deed4f..e5aa34119b 100644 --- a/src/3rdparty/chromium/sandbox/linux/BUILD.gn +++ b/src/3rdparty/chromium/sandbox/linux/BUILD.gn -@@ -400,6 +400,7 @@ source_set("sandbox_services_headers") { +@@ -393,6 +393,7 @@ source_set("sandbox_services_headers") { "system_headers/linux_time.h", "system_headers/mips64_linux_syscalls.h", "system_headers/mips_linux_syscalls.h", @@ -25,7 +20,6 @@ index 97e3deed4f..e5aa34119b 100644 "system_headers/x86_64_linux_syscalls.h", ] diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h -index 1d0590b7dd..3bf3cb2571 100644 --- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h +++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h @@ -56,6 +56,12 @@ @@ -42,7 +36,6 @@ index 1d0590b7dd..3bf3cb2571 100644 #error "Unsupported architecture" #endif diff --git a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h -index 87d5825aa3..49fc9a6701 100644 --- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h +++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/seccomp_macros.h @@ -343,6 +343,48 @@ struct regs_struct { @@ -95,7 +88,6 @@ index 87d5825aa3..49fc9a6701 100644 #error Unsupported target platform diff --git a/src/3rdparty/chromium/sandbox/linux/integration_tests/bpf_dsl_seccomp_unittest.cc b/src/3rdparty/chromium/sandbox/linux/integration_tests/bpf_dsl_seccomp_unittest.cc -index 7c72a05c2e..235aabadec 100644 --- a/src/3rdparty/chromium/sandbox/linux/integration_tests/bpf_dsl_seccomp_unittest.cc +++ b/src/3rdparty/chromium/sandbox/linux/integration_tests/bpf_dsl_seccomp_unittest.cc @@ -22,6 +22,7 @@ @@ -104,9 +96,9 @@ index 7c72a05c2e..235aabadec 100644 #include +#include + #include #include - #include -@@ -2032,7 +2033,15 @@ SANDBOX_TEST(SandboxBPF, DISABLE_ON_TSAN(SeccompRetTrace)) { +@@ -2033,7 +2034,15 @@ SANDBOX_TEST(SandboxBPF, DISABLE_ON_TSAN BPF_ASSERT_EQ(kTraceData, data); regs_struct regs; @@ -115,14 +107,14 @@ index 7c72a05c2e..235aabadec 100644 + iov.iov_base = ®s; + iov.iov_len = sizeof(regs); + BPF_ASSERT_NE(-1, ptrace(PTRACE_GETREGSET, pid, -+ reinterpret_case(NT_PRSTATUS), &iov)); ++ reinterpret_cast(NT_PRSTATUS), &iov)); +#else BPF_ASSERT_NE(-1, ptrace(PTRACE_GETREGS, pid, NULL, ®s)); +#endif switch (SECCOMP_PT_SYSCALL(regs)) { case __NR_write: // Skip writes to stdout, make it return kExpectedReturnValue. Allow -@@ -2040,7 +2049,14 @@ SANDBOX_TEST(SandboxBPF, DISABLE_ON_TSAN(SeccompRetTrace)) { +@@ -2041,7 +2050,14 @@ SANDBOX_TEST(SandboxBPF, DISABLE_ON_TSAN if (SECCOMP_PT_PARM1(regs) == STDOUT_FILENO) { BPF_ASSERT_NE(-1, SetSyscall(pid, ®s, -1)); SECCOMP_PT_RESULT(regs) = kExpectedReturnValue; @@ -137,7 +129,7 @@ index 7c72a05c2e..235aabadec 100644 } break; -@@ -2048,7 +2064,13 @@ SANDBOX_TEST(SandboxBPF, DISABLE_ON_TSAN(SeccompRetTrace)) { +@@ -2049,7 +2065,13 @@ SANDBOX_TEST(SandboxBPF, DISABLE_ON_TSAN // Rewrite to exit(kExpectedReturnValue). BPF_ASSERT_NE(-1, SetSyscall(pid, ®s, __NR_exit)); SECCOMP_PT_PARM1(regs) = kExpectedReturnValue; @@ -152,60 +144,31 @@ index 7c72a05c2e..235aabadec 100644 default: diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc -index 81877f27f5..545d4d0f6d 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc -@@ -59,6 +59,9 @@ bool IsBaselinePolicyAllowed(int sysno) { - #endif +@@ -60,6 +60,9 @@ bool IsBaselinePolicyAllowed(int sysno) #if defined(__mips__) SyscallSets::IsMipsPrivate(sysno) || -+#endif + #endif +#if defined(__riscv) + SyscallSets::IsRiscvPrivate(sysno) || - #endif ++#endif SyscallSets::IsAllowedOperationOnFd(sysno); // clang-format on -@@ -197,7 +200,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno, - return RestrictFcntlCommands(); - #endif - --#if !defined(__aarch64__) -+#if !defined(__aarch64__) && !defined(__riscv) - // fork() is never used as a system call (clone() is used instead), but we - // have seen it in fallback code on Android. - if (sysno == __NR_fork) { -@@ -259,7 +262,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno, - } + } +@@ -259,7 +262,7 @@ ResultExpr EvaluateSyscallImpl(int fs_de + // TODO(crbug.com/40528912): should i386 really be in this list? #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ - defined(__aarch64__) + defined(__aarch64__) || defined(__riscv) if (sysno == __NR_mmap) return RestrictMmapFlags(); #endif -@@ -280,7 +283,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno, - return RestrictPrctl(); - - #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \ -- defined(__aarch64__) -+ defined(__aarch64__) || defined(__riscv) - if (sysno == __NR_socketpair) { - // Only allow AF_UNIX, PF_UNIX. Crash if anything else is seen. - static_assert(AF_UNIX == PF_UNIX, -@@ -370,7 +373,7 @@ ResultExpr EvaluateSyscallImpl(int fs_denied_errno, - // Allow creating pipes, but don't allow weird flags to pipe2(). - // O_NOTIFICATION_PIPE (== O_EXCL) can be used to create - // "notification pipes", which are rarely used. --#if !defined(__aarch64__) -+#if !defined(__aarch64__) && !defined(__riscv) - if (sysno == __NR_pipe) { - return Allow(); - } diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc -index 8ab1833aeb..15a3e47a00 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc -@@ -275,7 +275,7 @@ BPF_TEST_C(BaselinePolicy, GetRandom, BaselinePolicy) { +@@ -275,7 +275,7 @@ BPF_TEST_C(BaselinePolicy, GetRandom, Ba } // Not all architectures can restrict the domain for socketpair(). @@ -233,18 +196,17 @@ index 8ab1833aeb..15a3e47a00 100644 TEST_BASELINE_SIGSYS(__NR_vserver) #endif diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc -index eb15334401..f319f74555 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc -@@ -42,6 +42,7 @@ +@@ -44,6 +44,7 @@ + #endif - #if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \ - !defined(__arm__) && !defined(__aarch64__) && \ -+ !defined(__riscv) && \ + #if BUILDFLAG(IS_LINUX) && !defined(__arm__) && !defined(__aarch64__) && \ ++ !defined(__riscv) && \ !defined(PTRACE_GET_THREAD_AREA) // Also include asm/ptrace-abi.h since ptrace.h in older libc (for instance // the one in Ubuntu 16.04 LTS) is missing PTRACE_GET_THREAD_AREA. -@@ -466,8 +467,10 @@ ResultExpr RestrictPtrace() { +@@ -484,8 +485,10 @@ ResultExpr RestrictPtrace() { #endif return Switch(request) .Cases({ @@ -256,7 +218,7 @@ index eb15334401..f319f74555 100644 PTRACE_GETREGSET, #endif #if defined(__arm__) -@@ -512,7 +515,7 @@ SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictSockSendFlags(int sysno) { +@@ -530,7 +533,7 @@ SANDBOX_EXPORT bpf_dsl::ResultExpr Restr break; #endif #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \ @@ -266,7 +228,6 @@ index eb15334401..f319f74555 100644 argIndex = 3; break; diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc -index 10e64a2c07..ddfd6a7c34 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions_unittests.cc @@ -7,6 +7,7 @@ @@ -278,7 +239,6 @@ index 10e64a2c07..ddfd6a7c34 100644 #include #include diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc -index e71c6cbb3f..642f98a830 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc @@ -103,7 +103,7 @@ bool SyscallSets::IsUmask(int sysno) { @@ -290,7 +250,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_access: // EPERM not a valid errno. case __NR_chmod: case __NR_chown: -@@ -129,14 +129,14 @@ bool SyscallSets::IsFileSystem(int sysno) { +@@ -129,14 +129,14 @@ bool SyscallSets::IsFileSystem(int sysno #endif case __NR_ustat: // Same as above. Deprecated. case __NR_utimes: @@ -307,7 +267,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_newfstatat: // fstatat(). EPERM not a valid errno. #elif defined(__i386__) || defined(__arm__) || \ (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) -@@ -241,7 +241,7 @@ bool SyscallSets::IsAllowedFileSystemAccessViaFd(int sysno) { +@@ -241,7 +241,7 @@ bool SyscallSets::IsAllowedFileSystemAcc case __NR_oldfstat: #endif #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -316,7 +276,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_sync_file_range: // EPERM not a valid errno. #elif defined(__arm__) case __NR_arm_sync_file_range: // EPERM not a valid errno. -@@ -260,7 +260,7 @@ bool SyscallSets::IsDeniedFileSystemAccessViaFd(int sysno) { +@@ -260,7 +260,7 @@ bool SyscallSets::IsDeniedFileSystemAcce #if defined(__i386__) || defined(__arm__) case __NR_fchown32: #endif @@ -325,7 +285,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_getdents: // EPERM not a valid errno. #endif case __NR_getdents64: // EPERM not a valid errno. -@@ -339,7 +339,7 @@ bool SyscallSets::IsProcessPrivilegeChange(int sysno) { +@@ -339,7 +339,7 @@ bool SyscallSets::IsProcessPrivilegeChan bool SyscallSets::IsProcessGroupOrSession(int sysno) { switch (sysno) { case __NR_setpgid: @@ -334,7 +294,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_getpgrp: #endif case __NR_setsid: -@@ -373,7 +373,7 @@ bool SyscallSets::IsAllowedSignalHandling(int sysno) { +@@ -373,7 +373,7 @@ bool SyscallSets::IsAllowedSignalHandlin case __NR_rt_sigqueueinfo: case __NR_rt_sigsuspend: case __NR_rt_tgsigqueueinfo: @@ -343,7 +303,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_signalfd: #endif case __NR_signalfd4: -@@ -397,12 +397,12 @@ bool SyscallSets::IsAllowedOperationOnFd(int sysno) { +@@ -397,12 +397,12 @@ bool SyscallSets::IsAllowedOperationOnFd switch (sysno) { case __NR_close: case __NR_dup: @@ -358,7 +318,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_shutdown: #endif return true; -@@ -441,7 +441,7 @@ bool SyscallSets::IsAllowedProcessStartOrDeath(int sysno) { +@@ -441,7 +441,7 @@ bool SyscallSets::IsAllowedProcessStartO return true; case __NR_clone: // Should be parameter-restricted. case __NR_setns: // Privileged. @@ -367,7 +327,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_fork: #endif #if defined(__i386__) || defined(__x86_64__) -@@ -452,7 +452,7 @@ bool SyscallSets::IsAllowedProcessStartOrDeath(int sysno) { +@@ -452,7 +452,7 @@ bool SyscallSets::IsAllowedProcessStartO #endif case __NR_set_tid_address: case __NR_unshare: @@ -376,7 +336,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_vfork: #endif default: -@@ -477,7 +477,7 @@ bool SyscallSets::IsAllowedFutex(int sysno) { +@@ -477,7 +477,7 @@ bool SyscallSets::IsAllowedFutex(int sys bool SyscallSets::IsAllowedEpoll(int sysno) { switch (sysno) { @@ -385,7 +345,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_epoll_create: case __NR_epoll_wait: #endif -@@ -499,7 +499,7 @@ bool SyscallSets::IsAllowedEpoll(int sysno) { +@@ -499,7 +499,7 @@ bool SyscallSets::IsAllowedEpoll(int sys bool SyscallSets::IsDeniedGetOrModifySocket(int sysno) { switch (sysno) { #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \ @@ -394,7 +354,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_accept: case __NR_accept4: case __NR_bind: -@@ -554,7 +554,7 @@ bool SyscallSets::IsAllowedAddressSpaceAccess(int sysno) { +@@ -554,7 +554,7 @@ bool SyscallSets::IsAllowedAddressSpaceA case __NR_mincore: case __NR_mlockall: #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -403,7 +363,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_mmap: #endif #if defined(__i386__) || defined(__arm__) || \ -@@ -587,7 +587,7 @@ bool SyscallSets::IsAllowedGeneralIo(int sysno) { +@@ -587,7 +587,7 @@ bool SyscallSets::IsAllowedGeneralIo(int (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) case __NR__llseek: #endif @@ -412,7 +372,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_poll: #endif case __NR_ppoll: -@@ -608,7 +608,7 @@ bool SyscallSets::IsAllowedGeneralIo(int sysno) { +@@ -608,7 +608,7 @@ bool SyscallSets::IsAllowedGeneralIo(int case __NR_recv: #endif #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \ @@ -421,7 +381,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_recvfrom: // Could specify source. case __NR_recvmsg: // Could specify source. #endif -@@ -636,7 +636,7 @@ bool SyscallSets::IsAllowedGeneralIo(int sysno) { +@@ -639,7 +639,7 @@ bool SyscallSets::IsAllowedGeneralIo(int case __NR_send: #endif #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \ @@ -430,7 +390,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_sendmsg: // Could specify destination. case __NR_sendto: // Could specify destination. #endif -@@ -653,7 +653,7 @@ bool SyscallSets::IsSockSendOneMsg(int sysno) { +@@ -656,7 +656,7 @@ bool SyscallSets::IsSockSendOneMsg(int s case __NR_send: #endif #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \ @@ -439,7 +399,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_sendmsg: // Could specify destination. case __NR_sendto: // Could specify destination. #endif -@@ -687,7 +687,7 @@ bool SyscallSets::IsSeccomp(int sysno) { +@@ -690,7 +690,7 @@ bool SyscallSets::IsSeccomp(int sysno) { bool SyscallSets::IsAllowedBasicScheduler(int sysno) { switch (sysno) { case __NR_sched_yield: @@ -448,7 +408,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_pause: #endif case __NR_nanosleep: -@@ -771,7 +771,7 @@ bool SyscallSets::IsNuma(int sysno) { +@@ -774,7 +774,7 @@ bool SyscallSets::IsNuma(int sysno) { case __NR_getcpu: case __NR_mbind: #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -457,7 +417,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_migrate_pages: #endif case __NR_move_pages: -@@ -806,7 +806,7 @@ bool SyscallSets::IsGlobalProcessEnvironment(int sysno) { +@@ -809,7 +809,7 @@ bool SyscallSets::IsGlobalProcessEnviron switch (sysno) { case __NR_acct: // Privileged. #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -466,7 +426,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_getrlimit: #endif #if defined(__i386__) || defined(__arm__) -@@ -841,7 +841,7 @@ bool SyscallSets::IsDebug(int sysno) { +@@ -844,7 +844,7 @@ bool SyscallSets::IsDebug(int sysno) { bool SyscallSets::IsGlobalSystemStatus(int sysno) { switch (sysno) { @@ -475,7 +435,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR__sysctl: case __NR_sysfs: #endif -@@ -859,7 +859,7 @@ bool SyscallSets::IsGlobalSystemStatus(int sysno) { +@@ -862,7 +862,7 @@ bool SyscallSets::IsGlobalSystemStatus(i bool SyscallSets::IsEventFd(int sysno) { switch (sysno) { @@ -484,7 +444,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_eventfd: #endif case __NR_eventfd2: -@@ -911,6 +911,7 @@ bool SyscallSets::IsKeyManagement(int sysno) { +@@ -914,6 +914,7 @@ bool SyscallSets::IsKeyManagement(int sy } #if defined(__x86_64__) || defined(__arm__) || defined(__aarch64__) || \ @@ -492,7 +452,7 @@ index e71c6cbb3f..642f98a830 100644 (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_64_BITS)) bool SyscallSets::IsSystemVSemaphores(int sysno) { switch (sysno) { -@@ -930,7 +931,7 @@ bool SyscallSets::IsSystemVSemaphores(int sysno) { +@@ -933,7 +934,7 @@ bool SyscallSets::IsSystemVSemaphores(in #endif #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \ @@ -501,7 +461,7 @@ index e71c6cbb3f..642f98a830 100644 (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_64_BITS)) // These give a lot of ambient authority and bypass the setuid sandbox. bool SyscallSets::IsSystemVSharedMemory(int sysno) { -@@ -947,6 +948,7 @@ bool SyscallSets::IsSystemVSharedMemory(int sysno) { +@@ -950,6 +951,7 @@ bool SyscallSets::IsSystemVSharedMemory( #endif #if defined(__x86_64__) || defined(__arm__) || defined(__aarch64__) || \ @@ -509,7 +469,7 @@ index e71c6cbb3f..642f98a830 100644 (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_64_BITS)) bool SyscallSets::IsSystemVMessageQueue(int sysno) { switch (sysno) { -@@ -978,6 +980,7 @@ bool SyscallSets::IsSystemVIpc(int sysno) { +@@ -981,6 +983,7 @@ bool SyscallSets::IsSystemVIpc(int sysno bool SyscallSets::IsAnySystemV(int sysno) { #if defined(__x86_64__) || defined(__arm__) || defined(__aarch64__) || \ @@ -517,7 +477,7 @@ index e71c6cbb3f..642f98a830 100644 (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_64_BITS)) return IsSystemVMessageQueue(sysno) || IsSystemVSemaphores(sysno) || IsSystemVSharedMemory(sysno); -@@ -1015,7 +1018,7 @@ bool SyscallSets::IsAdvancedScheduler(int sysno) { +@@ -1018,7 +1021,7 @@ bool SyscallSets::IsAdvancedScheduler(in bool SyscallSets::IsInotify(int sysno) { switch (sysno) { case __NR_inotify_add_watch: @@ -526,7 +486,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_inotify_init: #endif case __NR_inotify_init1: -@@ -1150,7 +1153,7 @@ bool SyscallSets::IsMisc(int sysno) { +@@ -1153,7 +1156,7 @@ bool SyscallSets::IsMisc(int sysno) { #if defined(__x86_64__) case __NR_tuxcall: #endif @@ -535,7 +495,7 @@ index e71c6cbb3f..642f98a830 100644 case __NR_vserver: #endif return true; -@@ -1209,6 +1212,18 @@ bool SyscallSets::IsMipsMisc(int sysno) { +@@ -1212,6 +1215,18 @@ bool SyscallSets::IsMipsMisc(int sysno) } #endif // defined(__mips__) @@ -555,7 +515,6 @@ index e71c6cbb3f..642f98a830 100644 switch (sysno) { case __NR_getitimer: diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h -index fa49942cb8..af841baac9 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h @@ -52,7 +52,7 @@ class SANDBOX_EXPORT SyscallSets { @@ -603,10 +562,9 @@ index fa49942cb8..af841baac9 100644 }; diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc -index 6b772c563c..7922e0f53f 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall.cc -@@ -23,7 +23,7 @@ namespace sandbox { +@@ -19,7 +19,7 @@ namespace sandbox { namespace { #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \ @@ -615,7 +573,7 @@ index 6b772c563c..7922e0f53f 100644 // Number that's not currently used by any Linux kernel ABIs. const int kInvalidSyscallNumber = 0x351d3; #else -@@ -313,6 +313,28 @@ asm(// We need to be able to tell the kernel exactly where we made a +@@ -309,6 +309,28 @@ asm(// We need to be able to tell the ke "2:ret\n" ".cfi_endproc\n" ".size SyscallAsm, .-SyscallAsm\n" @@ -637,14 +595,14 @@ index 6b772c563c..7922e0f53f 100644 + "ld a6, 48(a1)\n" + "ld a1, 8(a1)\n" + // Enter the kernel -+ "scall\n" ++ "ecall\n" + "2:ret\n" + ".cfi_endproc\n" + ".size SyscallAsm, .-SyscallAsm\n" #endif ); // asm -@@ -324,6 +346,10 @@ intptr_t SyscallAsm(intptr_t nr, const intptr_t args[6]); +@@ -320,6 +342,10 @@ intptr_t SyscallAsm(intptr_t nr, const i extern "C" { intptr_t SyscallAsm(intptr_t nr, const intptr_t args[8]); } @@ -655,7 +613,7 @@ index 6b772c563c..7922e0f53f 100644 #endif } // namespace -@@ -356,6 +382,10 @@ intptr_t Syscall::Call(int nr, +@@ -352,6 +378,10 @@ intptr_t Syscall::Call(int nr, // where that makes sense. #if defined(__mips__) const intptr_t args[8] = {p0, p1, p2, p3, p4, p5, p6, p7}; @@ -666,7 +624,7 @@ index 6b772c563c..7922e0f53f 100644 #else DCHECK_EQ(p6, 0) << " Support for syscalls with more than six arguments not " "added for this architecture"; -@@ -430,6 +460,8 @@ intptr_t Syscall::Call(int nr, +@@ -426,6 +456,8 @@ intptr_t Syscall::Call(int nr, ret = inout; } @@ -675,11 +633,22 @@ index 6b772c563c..7922e0f53f 100644 #else #error "Unimplemented architecture" #endif +diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall_unittest.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall_unittest.cc +--- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall_unittest.cc ++++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/syscall_unittest.cc +@@ -79,6 +79,8 @@ TEST(Syscall, WellKnownEntryPoint) { + EXPECT_EQ(0x0cu, LoadBehind(Syscall::Call(-1)) & 0x0000FFFF); + #elif defined(__aarch64__) + EXPECT_EQ(0xD4000001u, LoadBehind(Syscall::Call(-1))); // SVC 0 ++#elif defined(__riscv) ++ EXPECT_EQ(0x73u, LoadBehind(Syscall::Call(-1))); // ECALL + #else + #warning Incomplete test case; need port for target platform + #endif diff --git a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc -index 9fbefe3e8b..bca98f0a4b 100644 --- a/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc +++ b/src/3rdparty/chromium/sandbox/linux/seccomp-bpf/trap.cc -@@ -221,6 +221,18 @@ void Trap::SigSys(int nr, LinuxSigInfo* info, ucontext_t* ctx) { +@@ -221,6 +221,18 @@ void Trap::SigSys(int nr, LinuxSigInfo* SECCOMP_PARM6(ctx), SECCOMP_PARM7(ctx), SECCOMP_PARM8(ctx)); @@ -699,10 +668,9 @@ index 9fbefe3e8b..bca98f0a4b 100644 rc = Syscall::Call(SECCOMP_SYSCALL(ctx), SECCOMP_PARM1(ctx), diff --git a/src/3rdparty/chromium/sandbox/linux/services/credentials.cc b/src/3rdparty/chromium/sandbox/linux/services/credentials.cc -index 1dc91d70aa..179700ec2a 100644 --- a/src/3rdparty/chromium/sandbox/linux/services/credentials.cc +++ b/src/3rdparty/chromium/sandbox/linux/services/credentials.cc -@@ -87,7 +87,7 @@ bool ChrootToSafeEmptyDir() { +@@ -90,7 +90,7 @@ bool ChrootToSafeEmptyDir() { alignas(16) char stack_buf[PTHREAD_STACK_MIN_CONST]; #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \ @@ -712,10 +680,9 @@ index 1dc91d70aa..179700ec2a 100644 void* stack = stack_buf + sizeof(stack_buf); #else diff --git a/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc b/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc -index df4a991be8..95ab677c83 100644 --- a/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc +++ b/src/3rdparty/chromium/sandbox/linux/services/syscall_wrappers.cc -@@ -66,7 +66,7 @@ long sys_clone(unsigned long flags, +@@ -68,7 +68,7 @@ long sys_clone(unsigned long flags, #if defined(ARCH_CPU_X86_64) return syscall(__NR_clone, flags, child_stack, ptid, ctid, tls); #elif defined(ARCH_CPU_X86) || defined(ARCH_CPU_ARM_FAMILY) || \ @@ -725,10 +692,9 @@ index df4a991be8..95ab677c83 100644 return syscall(__NR_clone, flags, child_stack, ptid, tls, ctid); #endif diff --git a/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc b/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc -index 049f72232e..2e83d1edfe 100644 --- a/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc +++ b/src/3rdparty/chromium/sandbox/linux/syscall_broker/broker_process.cc -@@ -121,44 +121,46 @@ bool BrokerProcess::IsSyscallBrokerable(int sysno, bool fast_check) const { +@@ -120,44 +120,46 @@ bool BrokerProcess::IsSyscallBrokerable( // and are default disabled in Android. So, we should refuse to broker them // to be consistent with the platform's restrictions. switch (sysno) { @@ -782,7 +748,7 @@ index 049f72232e..2e83d1edfe 100644 case __NR_stat: case __NR_lstat: #endif -@@ -168,7 +170,7 @@ bool BrokerProcess::IsSyscallBrokerable(int sysno, bool fast_check) const { +@@ -167,7 +169,7 @@ bool BrokerProcess::IsSyscallBrokerable( #if defined(__NR_fstatat64) case __NR_fstatat64: #endif @@ -791,7 +757,7 @@ index 049f72232e..2e83d1edfe 100644 case __NR_newfstatat: #endif return !fast_check || policy_->allowed_command_set.test(COMMAND_STAT); -@@ -183,7 +185,7 @@ bool BrokerProcess::IsSyscallBrokerable(int sysno, bool fast_check) const { +@@ -182,7 +184,7 @@ bool BrokerProcess::IsSyscallBrokerable( return !fast_check || policy_->allowed_command_set.test(COMMAND_STAT); #endif @@ -801,10 +767,9 @@ index 049f72232e..2e83d1edfe 100644 return !fast_check || policy_->allowed_command_set.test(COMMAND_UNLINK); #endif diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h -index 8690a96eb0..dec2afc744 100644 --- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h +++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h -@@ -39,6 +39,10 @@ +@@ -40,6 +40,10 @@ #define EM_AARCH64 183 #endif @@ -815,7 +780,7 @@ index 8690a96eb0..dec2afc744 100644 #ifndef __AUDIT_ARCH_64BIT #define __AUDIT_ARCH_64BIT 0x80000000 #endif -@@ -71,6 +75,10 @@ +@@ -72,6 +76,10 @@ #define AUDIT_ARCH_AARCH64 (EM_AARCH64 | __AUDIT_ARCH_64BIT | __AUDIT_ARCH_LE) #endif @@ -827,7 +792,6 @@ index 8690a96eb0..dec2afc744 100644 #ifndef PR_SET_SECCOMP #define PR_SET_SECCOMP 22 diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h -index 69ccaf1081..2ffe30973c 100644 --- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h +++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_signal.h @@ -13,7 +13,7 @@ @@ -840,7 +804,6 @@ index 69ccaf1081..2ffe30973c 100644 #define LINUX_SIGHUP 1 #define LINUX_SIGINT 2 diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_stat.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_stat.h -index 3aae8cbced..74977adb53 100644 --- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_stat.h +++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_stat.h @@ -150,7 +150,7 @@ struct kernel_stat { @@ -853,7 +816,6 @@ index 3aae8cbced..74977adb53 100644 unsigned long st_dev; unsigned long st_ino; diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h -index 438147b401..d6de8c1cb2 100644 --- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h +++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_syscalls.h @@ -35,5 +35,9 @@ @@ -868,7 +830,6 @@ index 438147b401..d6de8c1cb2 100644 diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/riscv64_linux_syscalls.h b/src/3rdparty/chromium/sandbox/linux/system_headers/riscv64_linux_syscalls.h new file mode 100644 -index 0000000000..93460d7a50 --- /dev/null +++ b/src/3rdparty/chromium/sandbox/linux/system_headers/riscv64_linux_syscalls.h @@ -0,0 +1,1290 @@ @@ -2163,10 +2124,9 @@ index 0000000000..93460d7a50 + +#endif // SANDBOX_LINUX_SYSTEM_HEADERS_RISCV64_LINUX_SYSCALLS_H_ diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_cdm_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_cdm_policy_linux.cc -index 433720fa9d..482ce1d814 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_cdm_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_cdm_policy_linux.cc -@@ -33,7 +33,7 @@ ResultExpr CdmProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -33,7 +33,7 @@ ResultExpr CdmProcessPolicy::EvaluateSys case __NR_ftruncate: case __NR_fallocate: #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -2176,10 +2136,9 @@ index 433720fa9d..482ce1d814 100644 #endif #if defined(__i386__) || defined(__arm__) diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_cros_amd_gpu_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_cros_amd_gpu_policy_linux.cc -index df2567f749..41e158a292 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_cros_amd_gpu_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_cros_amd_gpu_policy_linux.cc -@@ -38,7 +38,7 @@ ResultExpr CrosAmdGpuProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -39,7 +39,7 @@ ResultExpr CrosAmdGpuProcessPolicy::Eval case __NR_sched_setscheduler: case __NR_sysinfo: case __NR_uname: @@ -2189,10 +2148,9 @@ index df2567f749..41e158a292 100644 case __NR_stat: #endif diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_gpu_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_gpu_policy_linux.cc -index ef49a63ee3..333425782c 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_gpu_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_gpu_policy_linux.cc -@@ -80,7 +80,7 @@ ResultExpr GpuProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -80,7 +80,7 @@ ResultExpr GpuProcessPolicy::EvaluateSys (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) case __NR_ftruncate64: #endif @@ -2202,10 +2160,9 @@ index ef49a63ee3..333425782c 100644 #endif case __NR_getdents64: diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_network_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_network_policy_linux.cc -index b624069526..7def9fea99 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_network_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_network_policy_linux.cc -@@ -260,7 +260,7 @@ ResultExpr NetworkProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -259,7 +259,7 @@ ResultExpr NetworkProcessPolicy::Evaluat case __NR_fdatasync: case __NR_fsync: case __NR_mremap: @@ -2215,10 +2172,9 @@ index b624069526..7def9fea99 100644 #endif case __NR_getdents64: diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_print_compositor_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_print_compositor_policy_linux.cc -index bff338a903..36acee528c 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_print_compositor_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_print_compositor_policy_linux.cc -@@ -33,7 +33,7 @@ ResultExpr PrintCompositorProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -33,7 +33,7 @@ ResultExpr PrintCompositorProcessPolicy: case __NR_fdatasync: case __NR_fsync: #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -2228,10 +2184,9 @@ index bff338a903..36acee528c 100644 #endif #if defined(__i386__) || defined(__arm__) diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc -index e33f17e2f5..848cb53a4f 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_renderer_policy_linux.cc -@@ -85,7 +85,7 @@ ResultExpr RendererProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -86,7 +86,7 @@ ResultExpr RendererProcessPolicy::Evalua case __NR_ftruncate64: #endif #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -2241,10 +2196,9 @@ index e33f17e2f5..848cb53a4f 100644 case __NR_setrlimit: // We allow setrlimit to dynamically adjust the address space limit as diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_service_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_service_policy_linux.cc -index 32754e67be..3f42eabba9 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_service_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_service_policy_linux.cc -@@ -26,7 +26,7 @@ ResultExpr ServiceProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -26,7 +26,7 @@ ResultExpr ServiceProcessPolicy::Evaluat return RestrictIoctl(); // Allow the system calls below. #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -2254,10 +2208,9 @@ index 32754e67be..3f42eabba9 100644 #endif #if defined(__i386__) || defined(__arm__) diff --git a/src/3rdparty/chromium/sandbox/policy/linux/bpf_utility_policy_linux.cc b/src/3rdparty/chromium/sandbox/policy/linux/bpf_utility_policy_linux.cc -index e299ce998b..ed1106898e 100644 --- a/src/3rdparty/chromium/sandbox/policy/linux/bpf_utility_policy_linux.cc +++ b/src/3rdparty/chromium/sandbox/policy/linux/bpf_utility_policy_linux.cc -@@ -34,7 +34,7 @@ ResultExpr UtilityProcessPolicy::EvaluateSyscall(int sysno) const { +@@ -34,7 +34,7 @@ ResultExpr UtilityProcessPolicy::Evaluat case __NR_fdatasync: case __NR_fsync: #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ diff --git a/SPECS/qt6-qtwebengine/0003-qtwebengine-add-missing-pipewire-headers.patch b/SPECS/qt6-qtwebengine/0003-qtwebengine-add-missing-pipewire-headers.patch deleted file mode 100644 index d30ab52969..0000000000 --- a/SPECS/qt6-qtwebengine/0003-qtwebengine-add-missing-pipewire-headers.patch +++ /dev/null @@ -1,57 +0,0 @@ -diff --git a/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/pipewire_session.h b/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/pipewire_session.h -index 84273ea695..825bb0000a 100644 ---- a/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/pipewire_session.h -+++ b/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/pipewire_session.h -@@ -11,8 +11,10 @@ - #ifndef MODULES_VIDEO_CAPTURE_LINUX_PIPEWIRE_SESSION_H_ - #define MODULES_VIDEO_CAPTURE_LINUX_PIPEWIRE_SESSION_H_ - --#include - #include -+#include -+#include -+#include - - #include - #include -diff --git a/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.cc b/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.cc -index f6cd57ac36..b9c579d2e3 100644 ---- a/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.cc -+++ b/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.cc -@@ -10,10 +10,21 @@ - - #include "modules/video_capture/linux/video_capture_pipewire.h" - -+#include -+#include -+#include -+#include - #include -+#include - #include -+#include - #include -+#include -+#include -+#include - #include -+#include -+#include - - #include - -diff --git a/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.h b/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.h -index 789f2034d3..7c1f9390fc 100644 ---- a/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.h -+++ b/src/3rdparty/chromium/third_party/webrtc/modules/video_capture/linux/video_capture_pipewire.h -@@ -11,6 +11,10 @@ - #ifndef MODULES_VIDEO_CAPTURE_LINUX_VIDEO_CAPTURE_PIPEWIRE_H_ - #define MODULES_VIDEO_CAPTURE_LINUX_VIDEO_CAPTURE_PIPEWIRE_H_ - -+#include -+#include -+#include -+ - #include "modules/video_capture/linux/pipewire_session.h" - #include "modules/video_capture/video_capture_defines.h" - #include "modules/video_capture/video_capture_impl.h" diff --git a/SPECS/qt6-qtwebengine/0003-riscv-misc.patch b/SPECS/qt6-qtwebengine/0003-riscv-misc.patch new file mode 100644 index 0000000000..6225a29419 --- /dev/null +++ b/SPECS/qt6-qtwebengine/0003-riscv-misc.patch @@ -0,0 +1,26 @@ +diff --git a/src/3rdparty/chromium/third_party/blink/renderer/platform/audio/delay.cc b/src/3rdparty/chromium/third_party/blink/renderer/platform/audio/delay.cc +--- a/src/3rdparty/chromium/third_party/blink/renderer/platform/audio/delay.cc ++++ b/src/3rdparty/chromium/third_party/blink/renderer/platform/audio/delay.cc +@@ -107,8 +107,8 @@ double Delay::DelayTime(float sample_rat + #if !(defined(ARCH_CPU_X86_FAMILY) || defined(CPU_ARM_NEON)) + // Default scalar versions if simd/neon are not available. + std::tuple Delay::ProcessARateVector( +- float* destination, +- uint32_t frames_to_process) const { ++ base::span destination, ++ size_t frames_to_process) const { + // We don't have a vectorized version, so just do nothing and return the 0 to + // indicate no frames processed and return the current write_index_. + return std::make_tuple(0, write_index_); +diff --git a/src/3rdparty/chromium/third_party/skia/modules/skcms/src/skcms_internals.h b/src/3rdparty/chromium/third_party/skia/modules/skcms/src/skcms_internals.h +--- a/src/3rdparty/chromium/third_party/skia/modules/skcms/src/skcms_internals.h ++++ b/src/3rdparty/chromium/third_party/skia/modules/skcms/src/skcms_internals.h +@@ -57,7 +57,7 @@ extern "C" { + #define SKCMS_HAS_MUSTTAIL 1 + #endif + #elif !defined(__clang__) && !defined(SKCMS_HAS_MUSTTAIL) +- #if __has_cpp_attribute(clang::musttail) ++ #if __has_cpp_attribute(clang::musttail) && !defined(__riscv) + #define SKCMS_HAS_MUSTTAIL 1 + #else + #define SKCMS_HAS_MUSTTAIL 0 diff --git a/SPECS/qt6-qtwebengine/0006-riscv-enable-v8-webasm.patch b/SPECS/qt6-qtwebengine/0004-riscv-enable-v8-webasm.patch similarity index 84% rename from SPECS/qt6-qtwebengine/0006-riscv-enable-v8-webasm.patch rename to SPECS/qt6-qtwebengine/0004-riscv-enable-v8-webasm.patch index 737257963a..5e1bd6e5df 100644 --- a/SPECS/qt6-qtwebengine/0006-riscv-enable-v8-webasm.patch +++ b/SPECS/qt6-qtwebengine/0004-riscv-enable-v8-webasm.patch @@ -1,8 +1,7 @@ diff --git a/src/pdf/CMakeLists.txt b/src/pdf/CMakeLists.txt -index a318051eae..512568d078 100644 --- a/src/pdf/CMakeLists.txt +++ b/src/pdf/CMakeLists.txt -@@ -137,7 +137,7 @@ foreach(arch ${archs}) +@@ -139,7 +139,7 @@ foreach(arch ${archs}) enable_web_speech=false chrome_pgo_phase=0 strip_absolute_paths_from_debug_symbols=false diff --git a/SPECS/qt6-qtwebengine/0007-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch b/SPECS/qt6-qtwebengine/0005-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch similarity index 70% rename from SPECS/qt6-qtwebengine/0007-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch rename to SPECS/qt6-qtwebengine/0005-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch index 7e51a8b89a..53cb85c215 100644 --- a/SPECS/qt6-qtwebengine/0007-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch +++ b/SPECS/qt6-qtwebengine/0005-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch @@ -1,3 +1,4 @@ +diff --git a/src/3rdparty/chromium/base/strings/to_string.h b/src/3rdparty/chromium/base/strings/to_string.h --- a/src/3rdparty/chromium/base/strings/to_string.h +++ b/src/3rdparty/chromium/base/strings/to_string.h @@ -6,6 +6,7 @@ @@ -5,12 +6,13 @@ #include +#include - #include - #include #include + #include + #include +diff --git a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h --- a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h -+++ a/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h -@@ -214,8 +214,11 @@ struct seccomp_notif_addfd { ++++ b/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h +@@ -215,8 +215,11 @@ #define SECCOMP_RET_INVALID 0x00010000U // Illegal return value #endif @@ -22,10 +24,11 @@ +#endif #endif // SANDBOX_LINUX_SYSTEM_HEADERS_LINUX_SECCOMP_H_ ---- a/src/3rdparty/chromium/v8/src/json/json-stringifier.cc 2025-11-14 07:55:10.000000000 +0000 -+++ b/src/3rdparty/chromium/v8/src/json/json-stringifier.cc 2026-06-18 05:56:31.648272572 +0000 -@@ -2902,9 +2902,11 @@ - +diff --git a/src/3rdparty/chromium/v8/src/json/json-stringifier.cc b/src/3rdparty/chromium/v8/src/json/json-stringifier.cc +--- a/src/3rdparty/chromium/v8/src/json/json-stringifier.cc ++++ b/src/3rdparty/chromium/v8/src/json/json-stringifier.cc +@@ -3391,9 +3391,11 @@ + for (; block + (stride - 1) < end; block += stride) { const auto input = hw::LoadU(tag, block); - const auto has_lower_than_0x20 = input < mask_0x20; @@ -37,27 +40,29 @@ + const auto has_0x22 = hw::Eq(input, mask_0x22); + const auto has_0x5c = hw::Eq(input, mask_0x5c); const auto result = hw::Or(hw::Or(has_lower_than_0x20, has_0x22), has_0x5c); - + // No character that needs escaping found in block. ---- a/src/3rdparty/chromium/third_party/libyuv/source/row_rvv.cc 2025-11-14 07:55:10.000000000 +0000 -+++ b/src/3rdparty/chromium/third_party/libyuv/source/row_rvv.cc 2026-06-20 10:09:23.592876393 +0000 +diff --git a/src/3rdparty/chromium/third_party/libyuv/source/row_rvv.cc b/src/3rdparty/chromium/third_party/libyuv/source/row_rvv.cc +--- a/src/3rdparty/chromium/third_party/libyuv/source/row_rvv.cc ++++ b/src/3rdparty/chromium/third_party/libyuv/source/row_rvv.cc @@ -17,9 +17,7 @@ - + #include "libyuv/row.h" - + -// This module is for clang rvv. GCC hasn't supported segment load & store. -#if !defined(LIBYUV_DISABLE_RVV) && defined(__riscv_vector) && \ - defined(__clang__) +#if !defined(LIBYUV_DISABLE_RVV) && defined(__riscv_vector) #include #include - ---- a/src/3rdparty/chromium/third_party/libyuv/source/scale_rvv.cc 2025-11-14 07:55:10.000000000 +0000 -+++ b/src/3rdparty/chromium/third_party/libyuv/source/scale_rvv.cc 2026-06-20 10:11:59.024821956 +0000 + +diff --git a/src/3rdparty/chromium/third_party/libyuv/source/scale_rvv.cc b/src/3rdparty/chromium/third_party/libyuv/source/scale_rvv.cc +--- a/src/3rdparty/chromium/third_party/libyuv/source/scale_rvv.cc ++++ b/src/3rdparty/chromium/third_party/libyuv/source/scale_rvv.cc @@ -18,9 +18,7 @@ #include "libyuv/row.h" #include "libyuv/scale_row.h" - + -// This module is for clang rvv. GCC hasn't supported segment load & store. -#if !defined(LIBYUV_DISABLE_RVV) && defined(__riscv_vector) && \ - defined(__clang__) diff --git a/SPECS/qt6-qtwebengine/0005-riscv-v8.patch b/SPECS/qt6-qtwebengine/0005-riscv-v8.patch deleted file mode 100644 index 098dd8992e..0000000000 --- a/SPECS/qt6-qtwebengine/0005-riscv-v8.patch +++ /dev/null @@ -1,811 +0,0 @@ -diff --git a/src/3rdparty/chromium/v8/src/builtins/riscv/builtins-riscv.cc b/src/3rdparty/chromium/v8/src/builtins/riscv/builtins-riscv.cc -index 4d637bd281..54960a8cb0 100644 ---- a/src/3rdparty/chromium/v8/src/builtins/riscv/builtins-riscv.cc -+++ b/src/3rdparty/chromium/v8/src/builtins/riscv/builtins-riscv.cc -@@ -996,6 +996,7 @@ void Builtins::Generate_BaselineOutOfLinePrologueDeopt(MacroAssembler* masm) { - } - - void Builtins::Generate_BaselineOutOfLinePrologue(MacroAssembler* masm) { -+ ASM_CODE_COMMENT(masm); - UseScratchRegisterScope temps(masm); - temps.Include({kScratchReg, kScratchReg2, s1}); - auto descriptor = -@@ -1016,11 +1017,14 @@ void Builtins::Generate_BaselineOutOfLinePrologue(MacroAssembler* masm) { - __ AssertFeedbackVector(feedback_vector, type); - } - -+#ifndef V8_ENABLE_LEAPTIERING - // Check for an tiering state. - Label flags_need_processing; - Register flags = temps.Acquire(); - __ LoadFeedbackVectorFlagsAndJumpIfNeedsProcessing( - flags, feedback_vector, CodeKind::BASELINE, &flags_need_processing); -+#endif -+ - { - UseScratchRegisterScope temps(masm); - ResetFeedbackVectorOsrUrgency(masm, feedback_vector, temps.Acquire()); -@@ -1096,6 +1100,7 @@ void Builtins::Generate_BaselineOutOfLinePrologue(MacroAssembler* masm) { - // TODO(v8:11429): Document this frame setup better. - __ Ret(); - -+#ifndef V8_ENABLE_LEAPTIERING - __ bind(&flags_need_processing); - { - ASM_CODE_COMMENT_STRING(masm, "Optimized marker check"); -@@ -1104,6 +1109,7 @@ void Builtins::Generate_BaselineOutOfLinePrologue(MacroAssembler* masm) { - __ OptimizeCodeOrTailCallOptimizedCodeSlot(flags, feedback_vector); - __ Trap(); - } -+#endif - - __ bind(&call_stack_guard); - { -@@ -1157,15 +1163,16 @@ void Builtins::Generate_InterpreterEntryTrampoline( - __ LoadFeedbackVector(feedback_vector, closure, a4, &push_stack_frame); - - #ifndef V8_JITLESS -+#ifndef V8_ENABLE_LEAPTIERING - // If feedback vector is valid, check for optimized code and update invocation - // count. -- - // Check the tiering state. - Label flags_need_processing; - Register flags = a4; - __ LoadFeedbackVectorFlagsAndJumpIfNeedsProcessing( - flags, feedback_vector, CodeKind::INTERPRETED_FUNCTION, - &flags_need_processing); -+#endif // V8_ENABLE_LEAPTIERING - ResetFeedbackVectorOsrUrgency(masm, feedback_vector, a4); - - // Increment invocation count for the function. -@@ -1323,10 +1330,13 @@ void Builtins::Generate_InterpreterEntryTrampoline( - __ Branch(&after_stack_check_interrupt); - - #ifndef V8_JITLESS -+#ifndef V8_ENABLE_LEAPTIERING - __ bind(&flags_need_processing); - __ OptimizeCodeOrTailCallOptimizedCodeSlot(flags, feedback_vector); -+#endif //! V8_ENABLE_LEAPTIERING - __ bind(&is_baseline); - { -+#ifndef V8_ENABLE_LEAPTIERING - // Load the feedback vector from the closure. - __ LoadTaggedField( - feedback_vector, -@@ -1347,7 +1357,6 @@ void Builtins::Generate_InterpreterEntryTrampoline( - __ LoadFeedbackVectorFlagsAndJumpIfNeedsProcessing( - flags, feedback_vector, CodeKind::BASELINE, &flags_need_processing); - --#ifndef V8_ENABLE_LEAPTIERING - // TODO(olivf, 42204201): This fastcase is difficult to support with the - // sandbox as it requires getting write access to the dispatch table. See - // `JSFunction::UpdateCode`. We might want to remove it for all -@@ -1357,9 +1366,9 @@ void Builtins::Generate_InterpreterEntryTrampoline( - static_assert(kJavaScriptCallCodeStartRegister == a2, "ABI mismatch"); - __ ReplaceClosureCodeWithOptimizedCode(a2, closure); - __ JumpCodeObject(a2, kJSEntrypointTag); --#endif // V8_ENABLE_LEAPTIERING -- - __ bind(&install_baseline_code); -+#endif // !V8_ENABLE_LEAPTIERING -+ - __ GenerateTailCallToReturnedCode(Runtime::kInstallBaselineCode); - } - #endif // !V8_JITLESS -@@ -2630,9 +2639,13 @@ void Builtins::Generate_CallFunction(MacroAssembler* masm, - // -- cp : the function context. - // ----------------------------------- - -+#ifdef V8_ENABLE_LEAPTIERING -+ __ InvokeFunctionCode(a1, no_reg, a0, InvokeType::kJump); -+#else - __ Lhu(a2, - FieldMemOperand(a2, SharedFunctionInfo::kFormalParameterCountOffset)); - __ InvokeFunctionCode(a1, no_reg, a2, a0, InvokeType::kJump); -+#endif - } - - namespace { -@@ -5084,9 +5097,13 @@ void Builtins::Generate_RestartFrameTrampoline(MacroAssembler* masm) { - // Pop return address and frame. - __ LeaveFrame(StackFrame::INTERPRETED); - -+#ifdef V8_ENABLE_LEAPTIERING -+ __ InvokeFunction(a1, a0, InvokeType::kJump, -+ ArgumentAdaptionMode::kDontAdapt); -+#else - __ li(a2, Operand(kDontAdaptArgumentsSentinel)); -- - __ InvokeFunction(a1, a2, a0, InvokeType::kJump); -+#endif - } - - #undef __ -diff --git a/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.cc b/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.cc -index 9cf77ceebc..0b04dcc30b 100644 ---- a/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.cc -+++ b/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.cc -@@ -209,24 +209,7 @@ void MacroAssembler::GenerateTailCallToReturnedCode( - Jump(a2); - } - --Condition MacroAssembler::LoadFeedbackVectorFlagsAndCheckIfNeedsProcessing( -- Register flags, Register feedback_vector, Register result, -- CodeKind current_code_kind) { -- ASM_CODE_COMMENT(this); -- DCHECK(!AreAliased(flags, feedback_vector)); -- DCHECK(CodeKindCanTierUp(current_code_kind)); -- -- Lhu(flags, FieldMemOperand(feedback_vector, FeedbackVector::kFlagsOffset)); -- uint32_t kFlagsMask = FeedbackVector::kFlagsTieringStateIsAnyRequested | -- FeedbackVector::kFlagsMaybeHasTurbofanCode | -- FeedbackVector::kFlagsLogNextExecution; -- if (current_code_kind != CodeKind::MAGLEV) { -- kFlagsMask |= FeedbackVector::kFlagsMaybeHasMaglevCode; -- } -- And(result, flags, Operand(kFlagsMask)); -- return ne; --} -- -+#ifndef V8_ENABLE_LEAPTIERING - // Read off the flags in the feedback vector and check if there - // is optimized code or a tiering state that needs to be processed. - void MacroAssembler::LoadFeedbackVectorFlagsAndJumpIfNeedsProcessing( -@@ -248,22 +231,6 @@ void MacroAssembler::OptimizeCodeOrTailCallOptimizedCodeSlot( - Register flags, Register feedback_vector) { - ASM_CODE_COMMENT(this); - DCHECK(!AreAliased(flags, feedback_vector)); --#ifdef V8_ENABLE_LEAPTIERING -- // In the leaptiering case, we don't load optimized code from the feedback -- // vector so only need to call CompileOptimized or FunctionLogNextExecution -- // here. See also LoadFeedbackVectorFlagsAndJumpIfNeedsProcessing above. -- Label needs_logging; -- { -- UseScratchRegisterScope temps(this); -- Register scratch = temps.Acquire(); -- And(scratch, flags, -- Operand(FeedbackVector::kFlagsTieringStateIsAnyRequested)); -- Branch(&needs_logging, eq, scratch, Operand(zero_reg)); -- } -- GenerateTailCallToReturnedCode(Runtime::kCompileOptimized); -- bind(&needs_logging); -- GenerateTailCallToReturnedCode(Runtime::kFunctionLogNextExecution); --#else - UseScratchRegisterScope temps(this); - temps.Include(t0, t1); - Label maybe_has_optimized_code, maybe_needs_logging; -@@ -296,8 +263,8 @@ void MacroAssembler::OptimizeCodeOrTailCallOptimizedCodeSlot( - FeedbackVector::kMaybeOptimizedCodeOffset)); - TailCallOptimizedCodeSlot(this, optimized_code_entry, temps.Acquire(), - temps.Acquire()); --#endif // V8_ENABLE_LEAPTIERING - } -+#endif // V8_ENABLE_LEAPTIERING - - void MacroAssembler::LoadIsolateField(const Register& rd, IsolateFieldId id) { - li(rd, ExternalReference::Create(id)); -@@ -5630,7 +5597,7 @@ void MacroAssembler::StackOverflowCheck(Register num_args, Register scratch1, - - void MacroAssembler::InvokePrologue(Register expected_parameter_count, - Register actual_parameter_count, -- Label* done, InvokeType type) { -+ InvokeType type) { - Label regular_invoke; - - // a0: actual arguments count -@@ -5649,8 +5616,7 @@ void MacroAssembler::InvokePrologue(Register expected_parameter_count, - Label stack_overflow; - { - UseScratchRegisterScope temps(this); -- StackOverflowCheck(expected_parameter_count, temps.Acquire(), -- temps.Acquire(), &stack_overflow); -+ StackOverflowCheck(expected_parameter_count, t0, t1, &stack_overflow); - } - // Underapplication. Move the arguments already in the stack, including the - // receiver and the return address. -@@ -5694,90 +5660,150 @@ void MacroAssembler::InvokePrologue(Register expected_parameter_count, - bind(®ular_invoke); - } - --void MacroAssembler::CheckDebugHook(Register fun, Register new_target, -- Register expected_parameter_count, -- Register actual_parameter_count) { -- Label skip_hook; -- { -- UseScratchRegisterScope temps(this); -- Register scratch = temps.Acquire(); -- li(scratch, -- ExternalReference::debug_hook_on_function_call_address(isolate())); -- Lb(scratch, MemOperand(scratch)); -- Branch(&skip_hook, eq, scratch, Operand(zero_reg)); -+void MacroAssembler::CallDebugOnFunctionCall( -+ Register fun, Register new_target, -+ Register expected_parameter_count_or_dispatch_handle, -+ Register actual_parameter_count) { -+ ASM_CODE_COMMENT(this); -+ DCHECK(!AreAliased(t0, fun, new_target, -+ expected_parameter_count_or_dispatch_handle, -+ actual_parameter_count)); -+ -+ // Load receiver to pass it later to DebugOnFunctionCall hook. -+ LoadReceiver(t0); -+ FrameScope frame( -+ this, has_frame() ? StackFrame::NO_FRAME_TYPE : StackFrame::INTERNAL); -+ -+ SmiTag(expected_parameter_count_or_dispatch_handle); -+ SmiTag(actual_parameter_count); -+ Push(expected_parameter_count_or_dispatch_handle, actual_parameter_count); -+ -+ if (new_target.is_valid()) { -+ Push(new_target); -+ } -+ Push(fun, fun, t0); -+ CallRuntime(Runtime::kDebugOnFunctionCall); -+ Pop(fun); -+ if (new_target.is_valid()) { -+ Pop(new_target); - } -- { -- // Load receiver to pass it later to DebugOnFunctionCall hook. -- UseScratchRegisterScope temps(this); -- Register receiver = temps.Acquire(); -- LoadReceiver(receiver); - -- FrameScope frame( -- this, has_frame() ? StackFrame::NO_FRAME_TYPE : StackFrame::INTERNAL); -- SmiTag(expected_parameter_count); -- Push(expected_parameter_count); -+ Pop(expected_parameter_count_or_dispatch_handle, actual_parameter_count); -+ SmiUntag(actual_parameter_count); -+ SmiUntag(expected_parameter_count_or_dispatch_handle); -+} - -- SmiTag(actual_parameter_count); -- Push(actual_parameter_count); -+#ifdef V8_ENABLE_LEAPTIERING -+void MacroAssembler::InvokeFunction( -+ Register function, Register actual_parameter_count, InvokeType type, -+ ArgumentAdaptionMode argument_adaption_mode) { -+ ASM_CODE_COMMENT(this); -+ // You can't call a function without a valid frame. -+ DCHECK(type == InvokeType::kJump || has_frame()); - -- if (new_target.is_valid()) { -- Push(new_target); -- } -- Push(fun); -- Push(fun); -- Push(receiver); -- CallRuntime(Runtime::kDebugOnFunctionCall); -- Pop(fun); -- if (new_target.is_valid()) { -- Pop(new_target); -- } -+ // Contract with called JS functions requires that function is passed in a1. -+ // (See FullCodeGenerator::Generate().) -+ DCHECK_EQ(function, a1); - -- Pop(actual_parameter_count); -- SmiUntag(actual_parameter_count); -+ // Set up the context. -+ LoadTaggedField(cp, FieldMemOperand(function, JSFunction::kContextOffset)); - -- Pop(expected_parameter_count); -- SmiUntag(expected_parameter_count); -- } -- bind(&skip_hook); -+ InvokeFunctionCode(function, no_reg, actual_parameter_count, type, -+ argument_adaption_mode); - } - --void MacroAssembler::InvokeFunctionCode(Register function, Register new_target, -- Register expected_parameter_count, -- Register actual_parameter_count, -- InvokeType type) { -+void MacroAssembler::InvokeFunctionWithNewTarget( -+ Register function, Register new_target, Register actual_parameter_count, -+ InvokeType type) { -+ ASM_CODE_COMMENT(this); -+ // You can't call a function without a valid frame. -+ DCHECK(type == InvokeType::kJump || has_frame()); -+ -+ // Contract with called JS functions requires that function is passed in a1. -+ // (See FullCodeGenerator::Generate().) -+ DCHECK_EQ(function, a1); -+ -+ LoadTaggedField(cp, FieldMemOperand(function, JSFunction::kContextOffset)); -+ -+ InvokeFunctionCode(function, new_target, actual_parameter_count, type); -+} -+ -+void MacroAssembler::InvokeFunctionCode( -+ Register function, Register new_target, Register actual_parameter_count, -+ InvokeType type, ArgumentAdaptionMode argument_adaption_mode) { -+ ASM_CODE_COMMENT(this); - // You can't call a function without a valid frame. - DCHECK_IMPLIES(type == InvokeType::kCall, has_frame()); - DCHECK_EQ(function, a1); - DCHECK_IMPLIES(new_target.is_valid(), new_target == a3); - -+ Register dispatch_handle = kJavaScriptCallDispatchHandleRegister; -+ Lw(dispatch_handle, -+ FieldMemOperand(function, JSFunction::kDispatchHandleOffset)); -+ - // On function call, call into the debugger if necessary. -- CheckDebugHook(function, new_target, expected_parameter_count, -- actual_parameter_count); -+ Label debug_hook, continue_after_hook; -+ { -+ li(t0, ExternalReference::debug_hook_on_function_call_address(isolate())); -+ Lb(t0, MemOperand(t0, 0)); -+ BranchShort(&debug_hook, ne, t0, Operand(zero_reg)); -+ } -+ bind(&continue_after_hook); - - // Clear the new.target register if not given. - if (!new_target.is_valid()) { - LoadRoot(a3, RootIndex::kUndefinedValue); - } - -- Label done; -- InvokePrologue(expected_parameter_count, actual_parameter_count, &done, type); -+ Register scratch = s1; -+ if (argument_adaption_mode == ArgumentAdaptionMode::kAdapt) { -+ Register expected_parameter_count = a2; -+ LoadParameterCountFromJSDispatchTable(expected_parameter_count, -+ dispatch_handle, scratch); -+ InvokePrologue(expected_parameter_count, actual_parameter_count, type); -+ } -+ - // We call indirectly through the code field in the function to - // allow recompilation to take effect without changing any of the - // call sites. -- constexpr int unused_argument_count = 0; -+ LoadEntrypointFromJSDispatchTable(kJavaScriptCallCodeStartRegister, -+ dispatch_handle, scratch); - switch (type) { - case InvokeType::kCall: -- CallJSFunction(function, unused_argument_count); -+ Call(kJavaScriptCallCodeStartRegister); - break; - case InvokeType::kJump: -- JumpJSFunction(function); -+ Jump(kJavaScriptCallCodeStartRegister); - break; - } -+ Label done; -+ Branch(&done); -+ -+ // Deferred debug hook. -+ bind(&debug_hook); -+ CallDebugOnFunctionCall(function, new_target, dispatch_handle, -+ actual_parameter_count); -+ Branch(&continue_after_hook); - -- // Continue here if InvokePrologue does handle the invocation due to -- // mismatched parameter counts. - bind(&done); - } -+#else // !V8_ENABLE_LEAPTIERING -+void MacroAssembler::InvokeFunction(Register function, -+ Register expected_parameter_count, -+ Register actual_parameter_count, -+ InvokeType type) { -+ // You can't call a function without a valid frame. -+ DCHECK_IMPLIES(type == InvokeType::kCall, has_frame()); -+ -+ // Contract with called JS functions requires that function is passed in a1. -+ DCHECK_EQ(function, a1); -+ -+ // Get the function and setup the context. -+ LoadTaggedField(cp, FieldMemOperand(a1, JSFunction::kContextOffset)); -+ -+ InvokeFunctionCode(a1, no_reg, expected_parameter_count, -+ actual_parameter_count, type); -+} - - void MacroAssembler::InvokeFunctionWithNewTarget( - Register function, Register new_target, Register actual_parameter_count, -@@ -5804,23 +5830,44 @@ void MacroAssembler::InvokeFunctionWithNewTarget( - actual_parameter_count, type); - } - --void MacroAssembler::InvokeFunction(Register function, -- Register expected_parameter_count, -- Register actual_parameter_count, -- InvokeType type) { -+void MacroAssembler::InvokeFunctionCode(Register function, Register new_target, -+ Register expected_parameter_count, -+ Register actual_parameter_count, -+ InvokeType type) { - // You can't call a function without a valid frame. - DCHECK_IMPLIES(type == InvokeType::kCall, has_frame()); -- -- // Contract with called JS functions requires that function is passed in a1. - DCHECK_EQ(function, a1); -+ DCHECK_IMPLIES(new_target.is_valid(), new_target == a3); - -- // Get the function and setup the context. -- LoadTaggedField(cp, FieldMemOperand(a1, JSFunction::kContextOffset)); -+ // On function call, call into the debugger if necessary. -+ CheckDebugHook(function, new_target, expected_parameter_count, -+ actual_parameter_count); - -- InvokeFunctionCode(a1, no_reg, expected_parameter_count, -- actual_parameter_count, type); --} -+ // Clear the new.target register if not given. -+ if (!new_target.is_valid()) { -+ LoadRoot(a3, RootIndex::kUndefinedValue); -+ } -+ -+ Label done; -+ InvokePrologue(expected_parameter_count, actual_parameter_count, &done, type); -+ // We call indirectly through the code field in the function to -+ // allow recompilation to take effect without changing any of the -+ // call sites. -+ constexpr int unused_argument_count = 0; -+ switch (type) { -+ case InvokeType::kCall: -+ CallJSFunction(function, unused_argument_count); -+ break; -+ case InvokeType::kJump: -+ JumpJSFunction(function); -+ break; -+ } - -+ // Continue here if InvokePrologue does handle the invocation due to -+ // mismatched parameter counts. -+ bind(&done); -+} -+#endif // V8_ENABLE_LEAPTIERING - // --------------------------------------------------------------------------- - // Support functions. - -@@ -7240,14 +7287,30 @@ void MacroAssembler::ComputeCodeStartAddress(Register dst) { - // 2. test kMarkedForDeoptimizationBit in those flags; and - // 3. if it is not zero then it jumps to the builtin. - void MacroAssembler::BailoutIfDeoptimized() { -- int offset = InstructionStream::kCodeOffset - InstructionStream::kHeaderSize; -- LoadProtectedPointerField( -- kScratchReg, MemOperand(kJavaScriptCallCodeStartRegister, offset)); -- Lw(kScratchReg, FieldMemOperand(kScratchReg, Code::kFlagsOffset)); -- And(kScratchReg, kScratchReg, -- Operand(1 << Code::kMarkedForDeoptimizationBit)); -- TailCallBuiltin(Builtin::kCompileLazyDeoptimizedCode, ne, kScratchReg, -+ ASM_CODE_COMMENT(this); -+ UseScratchRegisterScope temps(this); -+ Register scratch = temps.Acquire(); -+ if (v8_flags.debug_code || !V8_ENABLE_LEAPTIERING_BOOL) { -+ int offset = -+ InstructionStream::kCodeOffset - InstructionStream::kHeaderSize; -+ LoadProtectedPointerField( -+ scratch, MemOperand(kJavaScriptCallCodeStartRegister, offset)); -+ Lw(scratch, FieldMemOperand(scratch, Code::kFlagsOffset)); -+ } -+ -+#ifdef V8_ENABLE_LEAPTIERING -+ if (v8_flags.debug_code) { -+ Label not_deoptimized; -+ And(scratch, scratch, Operand(1 << Code::kMarkedForDeoptimizationBit)); -+ Branch(¬_deoptimized, eq, scratch, Operand(zero_reg)); -+ Abort(AbortReason::kInvalidDeoptimizedCode); -+ bind(¬_deoptimized); -+ } -+#else -+ And(scratch, scratch, Operand(1 << Code::kMarkedForDeoptimizationBit)); -+ TailCallBuiltin(Builtin::kCompileLazyDeoptimizedCode, ne, scratch, - Operand(zero_reg)); -+#endif - } - - void MacroAssembler::CallForDeoptimization(Builtin target, int, Label* exit, -@@ -7303,22 +7366,20 @@ void MacroAssembler::JumpCodeObject(Register code_object, CodeEntrypointTag tag, - } - - void MacroAssembler::CallJSFunction(Register function_object, -- uint16_t argument_count) { -- DCHECK_WITH_MSG(!V8_ENABLE_LEAPTIERING_BOOL, -- "argument_count is only used with Leaptiering"); -+ [[maybe_unused]] uint16_t argument_count) { - ASM_CODE_COMMENT(this); - Register code = kJavaScriptCallCodeStartRegister; - #ifdef V8_ENABLE_LEAPTIERING -- UseScratchRegisterScope temps(this); -- Register dispatch_handle = t0; -+ Register dispatch_handle = kJavaScriptCallDispatchHandleRegister; - Register parameter_count = t1; -+ UseScratchRegisterScope temps(this); - Register scratch = temps.Acquire(); - Lw(dispatch_handle, - FieldMemOperand(function_object, JSFunction::kDispatchHandleOffset)); - LoadEntrypointAndParameterCountFromJSDispatchTable(code, parameter_count, - dispatch_handle, scratch); - Label match; -- Branch(&match, le, parameter_count, Immediate(argument_count)); -+ Branch(&match, le, parameter_count, Operand(argument_count)); - // If the parameter count doesn't match, we force a safe crash by setting the - // code entrypoint to zero, causing a nullptr dereference during the call. - mv(code, zero_reg); -@@ -7366,13 +7427,14 @@ void MacroAssembler::JumpJSFunction(Register function_object, - ASM_CODE_COMMENT(this); - Register code = kJavaScriptCallCodeStartRegister; - #ifdef V8_ENABLE_LEAPTIERING -- LoadCodeEntrypointFromJSDispatchTable( -- code, -- FieldMemOperand(function_object, JSFunction::kDispatchHandleOffset)); -+ Register dispatch_handle = kJavaScriptCallDispatchHandleRegister; -+ UseScratchRegisterScope temps(this); -+ Register scratch = temps.Acquire(); -+ Lw(dispatch_handle, -+ FieldMemOperand(function_object, JSFunction::kDispatchHandleOffset)); -+ LoadEntrypointFromJSDispatchTable(code, dispatch_handle, scratch); - DCHECK_EQ(jump_mode, JumpMode::kJump); -- DCHECK_NE(code, t6); -- mv(t6, code); -- Jump(t6); -+ Jump(code); - #elif V8_ENABLE_SANDBOX - // When the sandbox is enabled, we can directly fetch the entrypoint pointer - // from the code pointer table instead of going through the Code object. In -@@ -7465,11 +7527,13 @@ void MacroAssembler::LoadEntrypointFromJSDispatchTable(Register destination, - Register scratch) { - DCHECK(!AreAliased(destination, scratch)); - ASM_CODE_COMMENT(this); -+ Register index = destination; - li(scratch, ExternalReference::js_dispatch_table_address()); - srli(index, dispatch_handle, kJSDispatchHandleShift); - slli(index, index, kJSDispatchTableEntrySizeLog2); - AddWord(scratch, scratch, index); -- Ld(destination, MemOperand(scratch, JSDispatchEntry::kEntrypointOffset)); -+ LoadWord(destination, -+ MemOperand(scratch, JSDispatchEntry::kEntrypointOffset)); - } - - void MacroAssembler::LoadEntrypointFromJSDispatchTable( -@@ -7486,7 +7550,7 @@ void MacroAssembler::LoadEntrypointFromJSDispatchTable( - static_assert(!JSDispatchTable::kSupportsCompaction); - int offset = JSDispatchTable::OffsetOfEntry(dispatch_handle) + - JSDispatchEntry::kEntrypointOffset; -- Ld(destination, MemOperand(scratch, offset)); -+ LoadWord(destination, MemOperand(scratch, offset)); - } - - void MacroAssembler::LoadParameterCountFromJSDispatchTable( -@@ -7494,12 +7558,14 @@ void MacroAssembler::LoadParameterCountFromJSDispatchTable( - DCHECK(!AreAliased(destination, scratch)); - ASM_CODE_COMMENT(this); - Register index = destination; -- li(scratch, ExternalReference::js_dispatch_table_address()); - srli(index, dispatch_handle, kJSDispatchHandleShift); - slli(index, index, kJSDispatchTableEntrySizeLog2); -+ li(scratch, ExternalReference::js_dispatch_table_address()); - AddWord(scratch, scratch, index); -+#ifdef V8_TARGET_ARCH_64_BIT - static_assert(JSDispatchEntry::kParameterCountMask == 0xffff); -- Lh(destination, MemOperand(scratch, JSDispatchEntry::kCodeObjectOffset)); -+#endif -+ Lhu(destination, MemOperand(scratch, JSDispatchEntry::kCodeObjectOffset)); - } - - void MacroAssembler::LoadEntrypointAndParameterCountFromJSDispatchTable( -@@ -7512,10 +7578,11 @@ void MacroAssembler::LoadEntrypointAndParameterCountFromJSDispatchTable( - srli(index, dispatch_handle, kJSDispatchHandleShift); - slli(index, index, kJSDispatchTableEntrySizeLog2); - AddWord(scratch, scratch, index); -- -- Ld(entrypoint, MemOperand(scratch, JSDispatchEntry::kEntrypointOffset)); -+ LoadWord(entrypoint, MemOperand(scratch, JSDispatchEntry::kEntrypointOffset)); -+#ifdef V8_TARGET_ARCH_64_BIT - static_assert(JSDispatchEntry::kParameterCountMask == 0xffff); -- Lh(parameter_count, MemOperand(scratch, JSDispatchEntry::kCodeObjectOffset)); -+#endif -+ Lhu(parameter_count, MemOperand(scratch, JSDispatchEntry::kCodeObjectOffset)); - } - #endif - -diff --git a/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.h b/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.h -index 12988bdf00..871f3640dd 100644 ---- a/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.h -+++ b/src/3rdparty/chromium/v8/src/codegen/riscv/macro-assembler-riscv.h -@@ -400,7 +400,6 @@ class V8_EXPORT_PRIVATE MacroAssembler : public MacroAssemblerBase { - push_helper(rs...); - } - -- template <> - void push_helper(Register r) { - StoreWord(r, MemOperand(sp, 0)); - } -@@ -548,7 +547,6 @@ class V8_EXPORT_PRIVATE MacroAssembler : public MacroAssemblerBase { - LoadWord(r, MemOperand(sp, sizeof...(rs) * kSystemPointerSize)); - } - -- template <> - void pop_helper(Register r) { - LoadWord(r, MemOperand(sp, 0)); - } -@@ -1600,23 +1598,47 @@ class V8_EXPORT_PRIVATE MacroAssembler : public MacroAssemblerBase { - // ------------------------------------------------------------------------- - // JavaScript invokes. - -- // Invoke the JavaScript function code by either calling or jumping. -- void InvokeFunctionCode(Register function, Register new_target, -- Register expected_parameter_count, -- Register actual_parameter_count, InvokeType type); -+ // On function call, call into the debugger. -+ void CallDebugOnFunctionCall( -+ Register fun, Register new_target, -+ Register expected_parameter_count_or_dispatch_handle, -+ Register actual_parameter_count); - -- // On function call, call into the debugger if necessary. -- void CheckDebugHook(Register fun, Register new_target, -- Register expected_parameter_count, -- Register actual_parameter_count); -+ // The way we invoke JSFunctions differs depending on whether leaptiering is -+ // enabled. As such, these functions exist in two variants. In the future, -+ // leaptiering will be used on all platforms. At that point, the -+ // non-leaptiering variants will disappear. - -+#ifdef V8_ENABLE_LEAPTIERING - // Invoke the JavaScript function in the given register. Changes the - // current context to the context in the function before invoking. -+ void InvokeFunction(Register function, Register actual_parameter_count, -+ InvokeType type, -+ ArgumentAdaptionMode argument_adaption_mode = -+ ArgumentAdaptionMode::kAdapt); -+ // Invoke the JavaScript function in the given register. -+ // Changes the current context to the context in the function before invoking. - void InvokeFunctionWithNewTarget(Register function, Register new_target, - Register actual_parameter_count, - InvokeType type); -+ // Invoke the JavaScript function code by either calling or jumping. -+ void InvokeFunctionCode(Register function, Register new_target, -+ Register actual_parameter_count, InvokeType type, -+ ArgumentAdaptionMode argument_adaption_mode = -+ ArgumentAdaptionMode::kAdapt); -+#else - void InvokeFunction(Register function, Register expected_parameter_count, - Register actual_parameter_count, InvokeType type); -+ // Invoke the JavaScript function in the given register. Changes the -+ // current context to the context in the function before invoking. -+ void InvokeFunctionWithNewTarget(Register function, Register new_target, -+ Register actual_parameter_count, -+ InvokeType type); -+ // Invoke the JavaScript function code by either calling or jumping. -+ void InvokeFunctionCode(Register function, Register new_target, -+ Register expected_parameter_count, -+ Register actual_parameter_count, InvokeType type); -+#endif - - // ---- InstructionStream generation helpers ---- - -@@ -1657,14 +1679,13 @@ class V8_EXPORT_PRIVATE MacroAssembler : public MacroAssemblerBase { - Register closure); - void GenerateTailCallToReturnedCode(Runtime::FunctionId function_id); - -- Condition LoadFeedbackVectorFlagsAndCheckIfNeedsProcessing( -- Register flags, Register feedback_vector, Register result, -- CodeKind current_code_kind); -+#ifndef V8_ENABLE_LEAPTIERING - void LoadFeedbackVectorFlagsAndJumpIfNeedsProcessing( - Register flags, Register feedback_vector, CodeKind current_code_kind, - Label* flags_need_processing); - void OptimizeCodeOrTailCallOptimizedCodeSlot(Register flags, - Register feedback_vector); -+#endif - - // ------------------------------------------------------------------------- - // Support functions. -@@ -1883,8 +1904,7 @@ class V8_EXPORT_PRIVATE MacroAssembler : public MacroAssemblerBase { - - // Helper functions for generating invokes. - void InvokePrologue(Register expected_parameter_count, -- Register actual_parameter_count, Label* done, -- InvokeType type); -+ Register actual_parameter_count, InvokeType type); - - // Compute memory operands for safepoint stack slots. - static int SafepointRegisterStackIndex(int reg_code); -diff --git a/src/3rdparty/chromium/v8/src/codegen/riscv/register-riscv.h b/src/3rdparty/chromium/v8/src/codegen/riscv/register-riscv.h -index ddf2f879d4..67321defed 100644 ---- a/src/3rdparty/chromium/v8/src/codegen/riscv/register-riscv.h -+++ b/src/3rdparty/chromium/v8/src/codegen/riscv/register-riscv.h -@@ -301,8 +301,7 @@ constexpr Register kJavaScriptCallCodeStartRegister = a2; - constexpr Register kJavaScriptCallTargetRegister = kJSFunctionRegister; - constexpr Register kJavaScriptCallNewTargetRegister = a3; - constexpr Register kJavaScriptCallExtraArg1Register = a2; --// Leaptiering is not currently available on riscv64. --constexpr Register kJavaScriptCallDispatchHandleRegister = no_reg; -+constexpr Register kJavaScriptCallDispatchHandleRegister = a4; - - constexpr Register kRuntimeCallFunctionRegister = a1; - constexpr Register kRuntimeCallArgCountRegister = a0; -diff --git a/src/3rdparty/chromium/v8/src/compiler/backend/riscv/code-generator-riscv.cc b/src/3rdparty/chromium/v8/src/compiler/backend/riscv/code-generator-riscv.cc -index 11c9e1c1a5..5cc2dcd21c 100644 ---- a/src/3rdparty/chromium/v8/src/compiler/backend/riscv/code-generator-riscv.cc -+++ b/src/3rdparty/chromium/v8/src/compiler/backend/riscv/code-generator-riscv.cc -@@ -706,6 +706,36 @@ void CodeGenerator::AssembleCodeStartRegisterCheck() { - kJavaScriptCallCodeStartRegister, Operand(kScratchReg)); - } - -+#ifdef V8_ENABLE_LEAPTIERING -+// Check that {kJavaScriptCallDispatchHandleRegister} is correct. -+void CodeGenerator::AssembleDispatchHandleRegisterCheck() { -+ DCHECK(linkage()->GetIncomingDescriptor()->IsJSFunctionCall()); -+ -+ // We currently don't check this for JS builtins as those are sometimes -+ // called directly (e.g. from other builtins) and not through the dispatch -+ // table. This is fine as builtin functions don't use the dispatch handle, -+ // but we could enable this check in the future if we make sure to pass the -+ // kInvalidDispatchHandle whenever we do a direct call to a JS builtin. -+ if (Builtins::IsBuiltinId(info()->builtin())) { -+ return; -+ } -+ -+ // For now, we only ensure that the register references a valid dispatch -+ // entry with the correct parameter count. In the future, we may also be able -+ // to check that the entry points back to this code. -+ UseScratchRegisterScope temps(masm()); -+ Register actual_parameter_count = temps.Acquire(); -+ { -+ UseScratchRegisterScope temps(masm()); -+ Register scratch = temps.Acquire(); -+ __ LoadParameterCountFromJSDispatchTable( -+ actual_parameter_count, kJavaScriptCallDispatchHandleRegister, scratch); -+ } -+ __ Assert(eq, AbortReason::kWrongFunctionDispatchHandle, -+ actual_parameter_count, Operand(parameter_count_)); -+} -+#endif // V8_ENABLE_LEAPTIERING -+ - // Check if the code object is marked for deoptimization. If it is, then it - // jumps to the CompileLazyDeoptimizedCode builtin. In order to do this we need - // to: -@@ -713,16 +743,7 @@ void CodeGenerator::AssembleCodeStartRegisterCheck() { - // the flags in the referenced {Code} object; - // 2. test kMarkedForDeoptimizationBit in those flags; and - // 3. if it is not zero then it jumps to the builtin. --void CodeGenerator::BailoutIfDeoptimized() { -- int offset = InstructionStream::kCodeOffset - InstructionStream::kHeaderSize; -- __ LoadProtectedPointerField( -- kScratchReg, MemOperand(kJavaScriptCallCodeStartRegister, offset)); -- __ Lw(kScratchReg, FieldMemOperand(kScratchReg, Code::kFlagsOffset)); -- __ And(kScratchReg, kScratchReg, -- Operand(1 << Code::kMarkedForDeoptimizationBit)); -- __ TailCallBuiltin(Builtin::kCompileLazyDeoptimizedCode, ne, kScratchReg, -- Operand(zero_reg)); --} -+void CodeGenerator::BailoutIfDeoptimized() { __ BailoutIfDeoptimized(); } - - // Assembles an instruction after register allocation, producing machine code. - CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction( -diff --git a/src/3rdparty/chromium/v8/src/maglev/riscv/maglev-assembler-riscv.cc b/src/3rdparty/chromium/v8/src/maglev/riscv/maglev-assembler-riscv.cc -index 9611e33d6b..8fb87746e6 100644 ---- a/src/3rdparty/chromium/v8/src/maglev/riscv/maglev-assembler-riscv.cc -+++ b/src/3rdparty/chromium/v8/src/maglev/riscv/maglev-assembler-riscv.cc -@@ -127,6 +127,7 @@ void MaglevAssembler::OSRPrologue(Graph* graph) { - } - - void MaglevAssembler::Prologue(Graph* graph) { -+ ASM_CODE_COMMENT(this); - MaglevAssembler::TemporaryRegisterScope temps(this); - // We add two extra registers to the scope. Ideally we could add all the - // allocatable general registers, except Context, JSFunction, NewTarget and -@@ -147,6 +148,7 @@ void MaglevAssembler::Prologue(Graph* graph) { - } - - // Tiering support. -+#ifndef V8_ENABLE_LEAPTIERING - if (v8_flags.turbofan) { - using D = MaglevOptimizeCodeOrTailCallOptimizedCodeSlotDescriptor; - Register flags = D::GetRegisterParameter(D::kFlags); -@@ -169,6 +171,7 @@ void MaglevAssembler::Prologue(Graph* graph) { - TailCallBuiltin(Builtin::kMaglevOptimizeCodeOrTailCallOptimizedCodeSlot, - needs_processing, flag_reg, Operand(zero_reg)); - } -+#endif - - EnterFrame(StackFrame::MAGLEV); - // Save arguments in frame. diff --git a/SPECS/qt6-qtwebengine/qt6-qtwebengine.spec b/SPECS/qt6-qtwebengine/qt6-qtwebengine.spec index a281e09bd5..997de21368 100644 --- a/SPECS/qt6-qtwebengine/qt6-qtwebengine.spec +++ b/SPECS/qt6-qtwebengine/qt6-qtwebengine.spec @@ -5,36 +5,31 @@ # SPDX-License-Identifier: MulanPSL-2.0 %define qt_module qtwebengine -%define real_version 6.10.1 -%define short_version 6.10 +%define real_version 6.11.1 +%define short_version 6.11 Name: qt6-qtwebengine -Version: 6.10.1 +Version: 6.11.1 Release: %autorelease Summary: Qt6 - QtWebEngine components License: LGPL-3.0-only OR GPL-3.0-only WITH Qt-GPL-exception-1.0 URL: https://www.qt.io VCS: git:https://github.com/qt/qtwebengine -#!RemoteAsset: sha256:77b5ea6186a0429a6b8e656faedd5cd3e8019d33856ee59637698ab578ead1e3 +#!RemoteAsset: sha256:679c66ccc6c158fc215e9c58ef160331ecd29974232e345c05161889f8667083 Source0: https://download.qt.io/official_releases/qt/%{short_version}/%{real_version}/submodules/%{qt_module}-everywhere-src-%{real_version}.tar.xz BuildSystem: cmake -# workaround FTBFS against kernel-headers-5.2.0+ -Patch0: 0001-qtwebengine-SIOCGSTAMP.patch # enable to link pipewire -Patch1: 0002-qtwebengine-link-pipewire.patch -## Upstreamable patches: -Patch2: 0003-qtwebengine-add-missing-pipewire-headers.patch +Patch0: 0001-qtwebengine-link-pipewire.patch %ifarch riscv64 # Patches from https://build.opensuse.org/package/show/openSUSE:Factory:RISCV/qt6-webengine -# At revision dd1924eb288d26a395e5cd4841bd51d6. -# Nov 09, 2025 -Patch3: 0004-riscv-sandbox.patch -Patch4: 0005-riscv-v8.patch -Patch5: 0006-riscv-enable-v8-webasm.patch +# Updated for Qt 6.11.1 (openSUSE Factory RISCV) +Patch1: 0002-riscv-sandbox.patch +Patch2: 0003-riscv-misc.patch +Patch3: 0004-riscv-enable-v8-webasm.patch %endif # Based on various upstream commits. -Patch6: 0007-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch +Patch4: 0005-adapt-chromium-to-gcc16-glibc2.43-and-rvv.patch BuildOption(conf): -DCMAKE_TOOLCHAIN_FILE="%{_libdir}/cmake/Qt6/qt.toolchain.cmake" BuildOption(conf): -DFEATURE_webengine_build_gn=ON