diff --git a/.gitignore b/.gitignore index 3f65fc9..d9b9799 100644 --- a/.gitignore +++ b/.gitignore @@ -14,3 +14,10 @@ /qtwebengine-everywhere-src-6.8.0-clean.tar.xz /qtwebengine-everywhere-src-6.8.1-clean.tar.xz /qtwebengine-everywhere-src-6.8.2-clean.tar.xz +/qtwebengine-everywhere-src-6.9.0-rc-clean.tar.xz +/qtwebengine-everywhere-src-6.9.0-clean.tar.xz +/qtwebengine-everywhere-src-6.9.1-clean.tar.xz +/qtwebengine-everywhere-src-6.9.2-clean.tar.xz +/qtwebengine-everywhere-src-6.10.0-rc-clean.tar.xz +/qtwebengine-everywhere-src-6.10.0-clean.tar.xz +/qtwebengine-everywhere-src-6.10.1-clean.tar.xz diff --git a/clean_qtwebengine.sh b/clean_qtwebengine.sh index 0453321..5189a83 100755 --- a/clean_qtwebengine.sh +++ b/clean_qtwebengine.sh @@ -21,7 +21,7 @@ if [ -z "$1" ] ; then echo "usage: ./clean_qtwebengine.sh VERSION" - echo "e.g.: ./clean_qtwebengine.sh 6.8.0" + echo "e.g.: ./clean_qtwebengine.sh 6.10.0" exit 1 fi diff --git a/prepare-ppc64.sh b/prepare-ppc64.sh old mode 100755 new mode 100644 diff --git a/qt6-qtwebengine.spec b/qt6-qtwebengine.spec index ae26bf6..ad75b37 100644 --- a/qt6-qtwebengine.spec +++ b/qt6-qtwebengine.spec @@ -5,14 +5,46 @@ # package-notes causes FTBFS (#2043178) %undefine _package_note_file -%global use_system_libxslt 1 -%global use_system_libxml 1 -%global use_system_libwebp 1 -%global use_system_jsoncpp 1 -%if 0%{?rhel} && 0%{?rhel} == 9 -%global use_system_libicu 0 -%else +# defines for Optional system libraries: +%global use_system_re2 1 %global use_system_libicu 1 +%global use_system_libwebp 1 +%global use_system_opus 1 +%global use_system_ffmpeg 1 +# libvpx is exclusive with VA-API support (libva) which is enabled by default +%global use_system_libvpx 0 +%global use_system_snappy 1 +%global use_system_glib 1 +%global use_system_zlib 1 +%global use_system_minizip 1 +%global use_system_libevent 1 +%global use_system_libxml 1 +%global use_system_lcms2 1 +%global use_system_libpng 1 +%global use_system_libtiff 1 +%global use_system_libjpeg 1 +%global use_system_libopenjpeg2 1 +%global use_system_harfbuzz 1 +%global use_system_freetype 1 +%global use_system_libpci 1 +%global use_system_libudev 1 + +%if 0%{?rhel} && 0%{?rhel} == 9 +%global use_system_re2 0 +%global use_system_libicu 0 +%global use_system_minizip 0 +%global use_system_harfbuzz 0 +%endif + +%if 0%{?rhel} && 0%{?rhel} == 10 +%global use_system_zlib 0 +%endif + +# ppc64le builds currently fail with V8/XFA enabled (qt 6.9.0) +%ifarch ppc64le +%global enable_pdf_v8 0 +%else +%global enable_pdf_v8 1 %endif %if 0%{?fedora} && 0%{?fedora} >= 39 @@ -20,8 +52,6 @@ %global use_system_py_six 1 %endif -%global use_system_re2 0 - # NEON support on ARM (detected at runtime) - disable this if you are hitting # FTBFS due to e.g. GCC bug https://bugzilla.redhat.com/show_bug.cgi?id=1282495 #global arm_neon 1 @@ -38,8 +68,6 @@ # webcore_debug v8base_debug %endif -#global prerelease rc - # spellchecking dictionary directory %global _qtwebengine_dictionaries_dir %{_qt6_datadir}/qtwebengine_dictionaries @@ -48,22 +76,36 @@ # and designer plugins %global __provides_exclude_from ^%{_qt6_plugindir}/.*\\.so$ +# FIXME: we cannot use any ~rc or similar suffix as the build +# would fail for having too long filename +#global unstable 1 +%if 0%{?unstable} +%global prerelease rc +%endif + %global examples 1 Summary: Qt6 - QtWebEngine components Name: qt6-qtwebengine -Version: 6.8.2 -Release: 4%{?dist} +Version: 6.10.1 +Release: 5%{?dist} # See LICENSE.GPL LICENSE.LGPL LGPL_EXCEPTION.txt, for details # See also http://qt-project.org/doc/qt-5.0/qtdoc/licensing.html # The other licenses are from Chromium and the code it bundles License: (LGPLv2 with exceptions or GPLv3 with exceptions) and BSD and LGPLv2+ and ASL 2.0 and IJG and MIT and GPLv2+ and ISC and OpenSSL and (MPLv1.1 or GPLv2 or LGPLv2) URL: http://www.qt.io +%global majmin %(echo %{version} | cut -d. -f1-2) +%global qt_version %(echo %{version} | cut -d~ -f1) + # cleaned tarball with patent-encumbered codecs removed from the bundled FFmpeg # ./qtwebengine-release.sh -# ./clean_qtwebengine.sh 6.4.1 -Source0: qtwebengine-everywhere-src-%{version}-clean.tar.xz +# ./clean_qtwebengine.sh 6.9.0 +%if 0%{?unstable} +Source0: %{qt_module}-everywhere-src-%{qt_version}-%{prerelease}-clean.tar.xz +%else +Source0: %{qt_module}-everywhere-src-%{version}-clean.tar.xz +%endif # cleanup scripts used above Source2: clean_qtwebengine.sh @@ -84,20 +126,28 @@ Patch3: qtwebengine-aarch64-new-stat.patch # Enable OpenH264 Patch4: qtwebengine-use-openh264.patch -# FTBS warning: elaborated-type-specifier for a scoped enum must not -# use the 'class' keyword -Patch50: qtwebengine-fix-build.patch +# FTBFS - /usr/include/bits/siginfo-consts.h:219:3: error: expected identifier +# 219 | SYS_SECCOMP = 1, /* Seccomp triggered. */ +Patch5: qtwebengine-chromium-141-glibc-2.42-SYS_SECCOMP.patch ## Upstream patches: # https://bugreports.qt.io/browse/QTBUG-129985 Patch80: qtwebengine-fix-arm-build.patch -Patch81: qtwebengine-fix-building-system-ffmpeg.patch +# Remove with Qt 6.10.2 +# https://codereview.qt-project.org/c/qt/qtwebengine/+/702597 +Patch81: qtwebengine-move-gpu-info-logging-to-gpu-thread.patch +# https://qt-project.atlassian.net/browse/QTBUG-142823 +Patch82: qtwebengine-fix-quick-popup-window-positioning-under-x11.patch ## Upstreamable patches: +Patch100: qtwebengine-add-missing-pipewire-headers.patch +Patch101: qtwebengine-fix-build-against-gcc16.patch ## ppc64le port -Patch200: qtwebengine-6.7-ppc64.patch +Patch200: qtwebengine-6.9-ppc64.patch Patch201: qtwebengine-chromium-ppc64.patch +# https://github.com/google/highway/commit/dcc0ca1cd4245ecff9e5ba50818e47d5e2ccf699 +Patch202: qtwebengine-chromium-ppc64-highway.patch # handled by qt6-srpm-macros, which defines %%qt6_qtwebengine_arches # FIXME use/update qt6_qtwebengine_arches @@ -105,10 +155,35 @@ Patch201: qtwebengine-chromium-ppc64.patch ExclusiveArch: aarch64 x86_64 ppc64le BuildRequires: cmake +BuildRequires: ninja-build >= 1.7.2 BuildRequires: make +%if 0%{?rhel} && 0%{?rhel} < 10 +BuildRequires: gcc-toolset-13 +BuildRequires: gcc-toolset-13-libatomic-devel +%else +BuildRequires: gcc-c++ +%endif + +# gn links statically (for now) +BuildRequires: libstdc++-static +BuildRequires: libatomic + +BuildRequires: %{__python3} +BuildRequires: python3-html5lib +BuildRequires: gperf +BuildRequires: bison +BuildRequires: flex +BuildRequires: perl-interpreter + +BuildRequires: nodejs >= 14.9 +BuildRequires: krb5-devel +BuildRequires: git-core + BuildRequires: qt6-srpm-macros BuildRequires: qt6-qtbase-devel BuildRequires: qt6-qtbase-private-devel +%{?_qt6_version:Requires: qt6-qtbase%{?_isa} = %{_qt6_version}} + # TODO: check of = is really needed or if >= would be good enough -- rex %{?_qt6:Requires: %{_qt6}%{?_isa} = %{_qt6_version}} BuildRequires: qt6-qtdeclarative-devel @@ -119,97 +194,126 @@ BuildRequires: qt6-qttools-static BuildRequires: qt6-qtquickcontrols2-devel BuildRequires: qt6-qtwebchannel-devel BuildRequires: qt6-qtwebsockets-devel -# for examples? -BuildRequires: ninja-build -BuildRequires: cmake -BuildRequires: bison -BuildRequires: flex -BuildRequires: gcc-c++ -%if 0%{?rhel} && 0%{?rhel} < 10 -BuildRequires: gcc-toolset-13 -BuildRequires: gcc-toolset-13-libatomic-devel -%endif -# gn links statically (for now) -BuildRequires: libstdc++-static -BuildRequires: git-core -BuildRequires: gperf -BuildRequires: krb5-devel -%if 0%{?use_system_libicu} -BuildRequires: libicu-devel >= 68 -%endif -BuildRequires: libatomic -BuildRequires: libjpeg-devel -BuildRequires: nodejs +BuildRequires: qt6-qthttpserver-devel + +# optional system libraries in the order of the -- Configure summary: listing %if 0%{?use_system_re2} -BuildRequires: re2-devel +BuildRequires: pkgconfig(re2) >= 11.0.0 +%else Provides: bundled(re2) %endif -BuildRequires: snappy-devel -BuildConflicts: minizip-devel +%if 0%{?use_system_libicu} +BuildRequires: libicu-devel >= 70 +%endif +%if 0%{?use_system_libwebp} +BuildRequires: pkgconfig(libwebp) >= 0.6.0 +%endif +%if 0%{?use_system_opus} +BuildRequires: pkgconfig(opus) >= 1.3.1 +%endif +%if %{?use_system_ffmpeg} +BuildRequires: pkgconfig(libavutil) >= 58.29.100 +BuildRequires: pkgconfig(libavcodec) >= 60.31.102 +BuildRequires: pkgconfig(libavformat) >= 60.16.100 +BuildRequires: pkgconfig(openh264) +%endif +%if %{?use_system_libvpx} +BuildRequires: pkgconfig(vpx) >= 1.10.0 +%endif +%if 0%{?use_system_snappy} +BuildRequires: pkgconfig(snappy) +%endif +%if 0%{?use_system_glib} +BuildRequires: pkgconfig(glib-2.0) +BuildRequires: pkgconfig(gobject-2.0) +BuildRequires: pkgconfig(gio-2.0) +%endif +%if %{?use_system_zlib} +BuildRequires: pkgconfig(zlib) +%endif +%if 0%{?use_system_minizip} +BuildRequires: pkgconfig(minizip) +%else Provides: bundled(minizip) = 2.8.1 +%endif +%if 0%{?use_system_libevent} +BuildRequires: pkgconfig(libevent) +%endif +%if %{?use_system_libxml} +BuildRequires: pkgconfig(libxml-2.0) +BuildRequires: pkgconfig(libxslt) +%else +# bundled as "libxml" +# see src/3rdparty/chromium/third_party/libxml/linux/include/libxml/xmlversion.h +Provides: bundled(libxml2) = 2.9.13 +# see src/3rdparty/chromium/third_party/libxslt/linux/config.h for version +Provides: bundled(libxslt) = 1.1.3 +%endif +%if 0%{?use_system_lcms2} +BuildRequires: pkgconfig(lcms2) +%endif +%if 0%{?use_system_libpng} +BuildRequires: pkgconfig(libpng) >= 1.6.0 +%endif +%if 0%{?use_system_libtiff} +BuildRequires: pkgconfig(libtiff-4) >= 4.2.0 +%endif +%if 0%{?use_system_libjpeg} +BuildRequires: pkgconfig(libjpeg) +%endif +%if 0%{?use_system_libopenjpeg2} +BuildRequires: pkgconfig(libopenjp2) +%endif +%if 0%{?use_system_harfbuzz} +BuildRequires: pkgconfig(harfbuzz) >= 4.3.0 +%endif +%if 0%{?use_system_freetype} +BuildRequires: pkgconfig(freetype2) >= 2.4.2 +BuildRequires: pkgconfig(fontconfig) +%endif +%if 0%{?use_system_libpci} +BuildRequires: pkgconfig(libpci) +%endif +%if 0%{?use_system_libudev} +BuildRequires: pkgconfig(libudev) +%endif + +# qpa-xcb support libraries +BuildRequires: pkgconfig(x11) +BuildRequires: pkgconfig(libdrm) +BuildRequires: pkgconfig(xcomposite) +BuildRequires: pkgconfig(xcursor) +BuildRequires: pkgconfig(xrandr) +BuildRequires: pkgconfig(xi) +BuildRequires: pkgconfig(xproto) +BuildRequires: pkgconfig(xshmfence) +BuildRequires: pkgconfig(xtst) +BuildRequires: pkgconfig(xkbcommon) +BuildRequires: pkgconfig(xkbfile) +BuildRequires: pkgconfig(xcb) + +# required for webrtc +BuildRequires: pkgconfig(xdamage) + +# required for alsa BuildRequires: pkgconfig(alsa) +# required for pulseaudio +BuildRequires: pkgconfig(libpulse) +# required for vaapi +BuildRequires: pkgconfig(libva) +# required for pipewire +BuildRequires: pkgconfig(libpipewire-0.3) + BuildRequires: pkgconfig(dbus-1) BuildRequires: pkgconfig(egl) BuildRequires: pkgconfig(epoxy) BuildRequires: pkgconfig(expat) -BuildRequires: pkgconfig(fontconfig) -BuildRequires: pkgconfig(freetype2) BuildRequires: pkgconfig(gbm) -BuildRequires: pkgconfig(gio-2.0) BuildRequires: pkgconfig(gl) -BuildRequires: pkgconfig(glib-2.0) -BuildRequires: pkgconfig(gobject-2.0) -BuildRequires: pkgconfig(harfbuzz) -%if 0%{?use_system_jsoncpp} -BuildRequires: pkgconfig(jsoncpp) -%endif -BuildRequires: pkgconfig(lcms2) BuildRequires: pkgconfig(libcap) -BuildRequires: pkgconfig(libdrm) -BuildRequires: pkgconfig(libevent) -BuildRequires: pkgconfig(libpci) -BuildRequires: pkgconfig(libpipewire-0.3) -BuildRequires: pkgconfig(libpng) -BuildRequires: pkgconfig(libpulse) -BuildRequires: pkgconfig(libudev) -%if 0%{?use_system_libwebp} -BuildRequires: pkgconfig(libwebp) >= 0.6.0 -%endif -BuildRequires: pkgconfig(nss) -BuildRequires: pkgconfig(opus) +BuildRequires: pkgconfig(nss) >= 3.26 BuildRequires: pkgconfig(poppler-cpp) -BuildRequires: pkgconfig(x11) -BuildRequires: pkgconfig(xcomposite) -BuildRequires: pkgconfig(xcursor) -BuildRequires: pkgconfig(xdamage) -BuildRequires: pkgconfig(xext) -BuildRequires: pkgconfig(xfixes) -BuildRequires: pkgconfig(xi) -BuildRequires: pkgconfig(xkbcommon) -BuildRequires: pkgconfig(xkbfile) -BuildRequires: pkgconfig(xrandr) -BuildRequires: pkgconfig(xrender) -%if ! (0%{?rhel} >= 10) -BuildRequires: pkgconfig(xscrnsaver) -%endif -BuildRequires: pkgconfig(xshmfence) -BuildRequires: pkgconfig(xtst) -BuildRequires: pkgconfig(zlib) -%if %{?use_system_libxslt} -BuildRequires: pkgconfig(libxslt) -%endif -%if %{?use_system_libxml} -BuildRequires: pkgconfig(libxml-2.0) -%endif -BuildRequires: perl-interpreter -BuildRequires: %{__python3} -BuildRequires: python3-html5lib -BuildRequires: pkgconfig(vpx) >= 1.8.0 -BuildRequires: pkgconfig(libavcodec) -BuildRequires: pkgconfig(libavformat) -BuildRequires: pkgconfig(libavutil) -BuildRequires: pkgconfig(openh264) -BuildRequires: pkgconfig(libva) + %if 0%{?fedora} && 0%{?fedora} >= 39 BuildRequires: python3-zombie-imp @@ -273,19 +377,9 @@ Provides: bundled(leveldb) = 1.23 Provides: bundled(libjingle) # see src/3rdparty/chromium/third_party/libsrtp/CHANGES for the version number Provides: bundled(libsrtp) = 2.4.0 -%if ! %{?use_system_libxml} -# bundled as "libxml" -# see src/3rdparty/chromium/third_party/libxml/linux/include/libxml/xmlversion.h -Provides: bundled(libxml2) = 2.9.13 -%endif -%if ! %{?use_system_libxslt} -# see src/3rdparty/chromium/third_party/libxslt/linux/config.h for version -Provides: bundled(libxslt) = 1.1.3 -%endif Provides: bundled(libyuv) = 1819 Provides: bundled(modp_b64) Provides: bundled(ots) -Provides: bundled(re2) # see src/3rdparty/chromium/third_party/protobuf/CHANGES.txt for the version Provides: bundled(protobuf) = 3.13.0.1 Provides: bundled(qcms) = 4 @@ -335,8 +429,6 @@ Provides: bundled(v8) = 11.8.172.18 # http://www.netlib.org/fdlibm/readme Provides: bundled(fdlibm) = 5.3 -%{?_qt6_version:Requires: qt6-qtbase%{?_isa} = %{_qt6_version}} - %description %{summary}. @@ -379,12 +471,12 @@ Requires: qt6-qtdeclarative-devel%{?_isa} %package -n qt6-qtpdf-examples Summary: Example files for qt6-qtpdf - +Requires: qt6-qtsvg%{?_isa} %description -n qt6-qtpdf-examples %{summary}. %prep -%setup -q -n %{qt_module}-everywhere-src-%{version}%{?prerelease:-%{prerelease}} -a20 +%setup -q -n %{qt_module}-everywhere-src-%{qt_version}%{?prerelease:-%{prerelease}} -a20 mv pulse src/3rdparty/chromium/ @@ -395,19 +487,26 @@ popd %patch -P2 -p1 -b .link-pipewire %patch -P3 -p1 -b .aarch64-new-stat %patch -P4 -p1 -b .use-openh264 - -%patch -P50 -p1 -b .fix-build.patch +%if 0%{?fedora} > 43 || 0%{?rhel} > 10 +%patch -P5 -p1 -b .chromium-141-glibc-2.42-SYS_SECCOMP +%endif ## upstream patches %patch -P80 -p1 -b .fix-arm-build -%patch -P81 -p1 -b .fix-building-system-ffmpeg +%patch -P81 -p1 -b .move-gpu-info-logging-to-gpu-thread +%patch -P82 -p1 -b .fix-quick-popup-window-positioning-under-x11 ## upstreamable patches +%patch -P100 -p1 -b .add-missing-pipewire-headers +%patch -P101 -p1 -b .fix-build-against-gcc16 # ppc64le support %patch -P200 -p1 pushd src/3rdparty/chromium %patch -P201 -p1 +pushd third_party/highway/src +%patch -P202 -p1 +popd popd @@ -426,27 +525,23 @@ ln -s /usr/lib/python%{python3_version}/site-packages/six.py src/3rdparty/chromi ln -s /usr/lib/python%{python3_version}/site-packages/six.py src/3rdparty/chromium/third_party/wpt_tools/wpt/tools/third_party/six/six.py %endif -%if 0%{?use_system_re2} +#%%if 0%{?use_system_re2} # http://bugzilla.redhat.com/1337585 # can't just delete, but we'll overwrite with system headers to be on the safe side -cp -bv /usr/include/re2/*.h src/3rdparty/chromium/third_party/re2/src/re2/ -%endif +#cp -bv /usr/include/re2/*.h src/3rdparty/chromium/third_party/re2/src/re2/ +#%%endif # copy the Chromium license so it is installed with the appropriate name cp -p src/3rdparty/chromium/LICENSE LICENSE.Chromium -# use system libraries +# use system libraries not handled by cmake options correctly system_libs=() -%if %{?use_system_libxml} - system_libs+=(libxml) -%endif -%if %{?use_system_libxslt} - system_libs+=(libxslt) -%endif +%if %{?use_system_ffmpeg} +system_libs+=(ffmpeg) system_libs+=(openh264) - -# Use system OpenH264 +%endif +# Use system libraries src/3rdparty/chromium/build/linux/unbundle/replace_gn_files.py --system-libraries ${system_libs[@]} # consider doing this as part of the tarball creation step instead? rdieter @@ -468,21 +563,61 @@ export STRIP=strip export NINJAFLAGS="%{__ninja_common_opts}" export NINJA_PATH=%{__ninja} +# this follows the logic of the Configure summary to turn on and off %cmake_qt6 \ -DCMAKE_TOOLCHAIN_FILE:STRING="%{_libdir}/cmake/Qt6/qt.toolchain.cmake" \ - -DFEATURE_qtpdf_build:BOOL=ON \ + -DFEATURE_webengine_build_gn:BOOL=ON \ + -DFEATURE_webengine_jumbo_build:BOOL=ON \ -DFEATURE_webengine_developer_build:BOOL=OFF \ + -DFEATURE_qtwebengine_build:BOOL=ON \ + -DFEATURE_qtwebengine_core_build:BOOL=ON \ + -DFEATURE_qtwebengine_widgets_build:BOOL=ON \ + -DFEATURE_qtwebengine_quick_build:BOOL=ON \ + -DFEATURE_qtpdf_build:BOOL=ON \ + -DFEATURE_qtpdf_widgets_build:BOOL=ON \ + -DFEATURE_qtpdf_quick_build:BOOL=ON \ + -DFEATURE_webengine_system_re2:BOOL=%{?use_system_re2} \ + -DFEATURE_webengine_system_icu:BOOL=%{?use_system_libicu} \ + -DFEATURE_webengine_system_libwebp:BOOL=%{?use_system_libwebp} \ + -DFEATURE_webengine_system_opus:BOOL=%{?use_system_opus} \ + -DFEATURE_webengine_system_ffmpeg:BOOL=%{?use_system_ffmpeg} \ + -DFEATURE_webengine_system_libvpx:BOOL=%{?use_system_libvpx} \ + -DFEATURE_webengine_system_snappy:BOOL=%{?use_system_snappy} \ + -DFEATURE_webengine_system_glib:BOOL=%{?use_system_glib} \ + -DFEATURE_webengine_system_zlib:BOOL=%{?use_system_zlib} \ + -DFEATURE_webengine_system_minizip:BOOL=%{?use_system_minizip} \ + -DFEATURE_webengine_system_libevent:BOOL=%{?use_system_libevent} \ + -DFEATURE_webengine_system_libxml:BOOL=%{?use_system_libxml} \ + -DFEATURE_webengine_system_lcms2:BOOL=%{?use_system_lcms2} \ + -DFEATURE_webengine_system_libpng:BOOL=%{?use_system_libpng} \ + -DFEATURE_webengine_system_libtiff:BOOL=%{?use_system_libtiff} \ + -DFEATURE_webengine_system_libjpeg:BOOL=%{?use_system_libjpeg} \ + -DFEATURE_webengine_system_libopenjpeg2:BOOL=%{?use_system_libopenjpeg2} \ + -DFEATURE_webengine_system_harfbuzz:BOOL=%{?use_system_harfbuzz} \ + -DFEATURE_webengine_system_freetype:BOOL=%{?use_system_freetype} \ + -DFEATURE_webengine_system_libpci:BOOL=%{?use_system_libpci} \ + -DFEATURE_webengine_system_libudev:BOOL=%{?use_system_libudev} \ -DFEATURE_webengine_embedded_build:BOOL=OFF \ - -DFEATURE_webengine_extensions:BOOL=ON \ - -DFEATURE_webengine_kerberos:BOOL=ON \ - -DFEATURE_webengine_native_spellchecker:BOOL=OFF \ + -DFEATURE_webengine_pepper_plugins:BOOL=ON \ -DFEATURE_webengine_printing_and_pdf:BOOL=ON \ -DFEATURE_webengine_proprietary_codecs:BOOL=ON \ - -DFEATURE_webengine_system_icu:BOOL=%{?use_system_libicu} \ - -DFEATURE_webengine_system_libevent:BOOL=ON \ - -DFEATURE_webengine_system_ffmpeg:BOOL=ON \ + -DFEATURE_webengine_spellchecker:BOOL=ON \ + -DFEATURE_webengine_native_spellchecker:BOOL=OFF \ -DFEATURE_webengine_webrtc:BOOL=ON \ -DFEATURE_webengine_webrtc_pipewire:BOOL=ON \ + -DFEATURE_webengine_geolocation:BOOL=ON \ + -DFEATURE_webengine_webchannel:BOOL=ON \ + -DFEATURE_webengine_kerberos:BOOL=ON \ + -DFEATURE_webengine_extensions:BOOL=ON \ + -DFEATURE_webengine_ozone_x11:BOOL=ON \ + -DFEATURE_webengine_vulkan:BOOL=ON \ + -DFEATURE_webengine_vaapi:BOOL=ON \ + -DFEATURE_webengine_system_alsa:BOOL=ON \ + -DFEATURE_webengine_system_pulseaudio:BOOL=ON \ + -DFEATURE_webengine_system_gbm:BOOL=ON \ + -DFEATURE_webengine_v8_context_snapshot:BOOL=ON \ + -DFEATURE_webenginedriver:BOOL=ON \ + -DFEATURE_pdf_v8:BOOL=%{?enable_pdf_v8} \ -DQT_BUILD_EXAMPLES:BOOL=%{?examples:ON}%{!?examples:OFF} \ -DQT_INSTALL_EXAMPLES_SOURCES=%{?examples:ON}%{!?examples:OFF} @@ -636,21 +771,27 @@ done %{_qt6_libdir}/libQt6WebEngineQuick.prl %{_qt6_libdir}/libQt6WebEngineQuickDelegatesQml.prl %{_qt6_libdir}/libQt6WebEngineWidgets.prl +%dir %{_qt6_libdir}/cmake/Qt6Designer +%dir %{_qt6_libdir}/cmake/Qt6WebEngineCore +%dir %{_qt6_libdir}/cmake/Qt6WebEngineCorePrivate +%dir %{_qt6_libdir}/cmake/Qt6WebEngineCoreTools +%dir %{_qt6_libdir}/cmake/Qt6WebEngineQuick +%dir %{_qt6_libdir}/cmake/Qt6WebEngineQuickDelegatesQml +%dir %{_qt6_libdir}/cmake/Qt6WebEngineQuickPrivate +%dir %{_qt6_libdir}/cmake/Qt6WebEngineWidgets +%dir %{_qt6_libdir}/cmake/Qt6WebEngineWidgetsPrivate %{_qt6_libdir}/cmake/Qt6/*.cmake %{_qt6_libdir}/cmake/Qt6BuildInternals/StandaloneTests/QtWebEngine* -%{_qt6_libdir}/cmake/Qt6Qml/QmlPlugins/Qt6qtwebengine*.cmake -%dir %{_qt6_libdir}/cmake/Qt6Designer %{_qt6_libdir}/cmake/Qt6Designer/Qt6QWebEngine*.cmake -%dir %{_qt6_libdir}/cmake/Qt6WebEngineQuick -%{_qt6_libdir}/cmake/Qt6WebEngineQuick/*.cmake -%dir %{_qt6_libdir}/cmake/Qt6WebEngineWidgets -%{_qt6_libdir}/cmake/Qt6WebEngineWidgets/*.cmake -%dir %{_qt6_libdir}/cmake/Qt6WebEngineCore +%{_qt6_libdir}/cmake/Qt6Qml/QmlPlugins/Qt6qtwebengine*.cmake %{_qt6_libdir}/cmake/Qt6WebEngineCore/*.cmake -%dir %{_qt6_libdir}/cmake/Qt6WebEngineCoreTools +%{_qt6_libdir}/cmake/Qt6WebEngineCorePrivate/*.cmake %{_qt6_libdir}/cmake/Qt6WebEngineCoreTools/*.cmake -%dir %{_qt6_libdir}/cmake/Qt6WebEngineQuickDelegatesQml +%{_qt6_libdir}/cmake/Qt6WebEngineQuick/*.cmake %{_qt6_libdir}/cmake/Qt6WebEngineQuickDelegatesQml/*.cmake +%{_qt6_libdir}/cmake/Qt6WebEngineQuickPrivate/*.cmake +%{_qt6_libdir}/cmake/Qt6WebEngineWidgets/*.cmake +%{_qt6_libdir}/cmake/Qt6WebEngineWidgetsPrivate/*.cmake %{_qt6_libdir}/pkgconfig/Qt6WebEngineCore.pc %{_qt6_libdir}/pkgconfig/Qt6WebEngineQuick.pc %{_qt6_libdir}/pkgconfig/Qt6WebEngineQuickDelegatesQml.pc @@ -690,13 +831,19 @@ done %{_qt6_libdir}/libQt6Pdf.prl %{_qt6_libdir}/libQt6PdfQuick.prl %{_qt6_libdir}/libQt6PdfWidgets.prl -%{_qt6_libdir}/cmake/Qt6Gui/Qt6QPdf*.cmake %dir %{_qt6_libdir}/cmake/Qt6Pdf -%{_qt6_libdir}/cmake/Qt6Pdf/*.cmake +%dir %{_qt6_libdir}/cmake/Qt6PdfPrivate %dir %{_qt6_libdir}/cmake/Qt6PdfQuick -%{_qt6_libdir}/cmake/Qt6PdfQuick/*.cmake +%dir %{_qt6_libdir}/cmake/Qt6PdfQuickPrivate %dir %{_qt6_libdir}/cmake/Qt6PdfWidgets +%dir %{_qt6_libdir}/cmake/Qt6PdfWidgetsPrivate +%{_qt6_libdir}/cmake/Qt6Gui/Qt6QPdf*.cmake +%{_qt6_libdir}/cmake/Qt6Pdf/*.cmake +%{_qt6_libdir}/cmake/Qt6PdfPrivate/*.cmake +%{_qt6_libdir}/cmake/Qt6PdfQuick/*.cmake +%{_qt6_libdir}/cmake/Qt6PdfQuickPrivate/*.cmake %{_qt6_libdir}/cmake/Qt6PdfWidgets/*.cmake +%{_qt6_libdir}/cmake/Qt6PdfWidgetsPrivate/*.cmake %{_qt6_libdir}/cmake/Qt6Qml/QmlPlugins/Qt6Pdf*.cmake %{_qt6_libdir}/pkgconfig/Qt6Pdf.pc %{_qt6_libdir}/pkgconfig/Qt6PdfQuick.pc @@ -709,6 +856,61 @@ done %endif %changelog +* Tue Jan 13 2026 Jan Grulich - 6.10.1-5 +- Fix Quick popup window positioning under X11 + +* Sun Jan 11 2026 Jan Grulich - 6.10.1-4 +- Apply the "Move GPU info logging into the GPU thread" patch + +* Thu Jan 08 2026 Jan Grulich - 6.10.1-3 +- Move GPU info logging into the GPU thread + +* Fri Nov 21 2025 Jan Grulich - 6.10.1-2 +- Rebuild for Koji infra issue + +* Thu Nov 20 2025 Jan Grulich - 6.10.1-1 +- 6.10.1 + +* Thu Oct 30 2025 Dominik Mierzejewski - 6.10.0-4 +- Rebuilt for FFmpeg 8 + +* Thu Oct 30 2025 Jan Grulich - 6.10.0-3 +- Fix FTBS in rawhide due to glib and PipeWire updates + +* Tue Oct 07 2025 Jan Grulich - 6.10.0-2 +- 6.10.0 + +* Thu Sep 25 2025 Jan Grulich - 6.10.0~rc-1 +- 6.10.0 RC + +* Mon Sep 08 2025 Sandro Mani - 6.9.2-2 +- Revert commit bcee2dbf412cc655c1b467091b581c696d234e3f + +* Fri Aug 29 2025 Jan Grulich - 6.9.2-1 +- 6.9.2 + +* Wed Aug 06 2025 František Zatloukal - 6.9.1-3 +- Rebuilt for icu 77.1 + +* Fri Jul 25 2025 Fedora Release Engineering - 6.9.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + +* Tue Jun 03 2025 Jan Grulich - 6.9.1-1 +- 6.9.1 + +* Tue Apr 22 2025 Marie Loise Nolden - 6.9.0-2 +- global define all optional system libs, enable XFA +- cleanup spec + +* Wed Apr 02 2025 Jan Grulich - 6.9.0-1 +- 6.9.0 + +* Mon Mar 24 2025 Jan Grulich - 6.9.0-0.1 +- 6.9.0 RC + +* Thu Mar 13 2025 Fabio Valentini - 6.8.2-5 +- Rebuild for noopenh264 2.6.0 + * Tue Mar 04 2025 Jan Grulich - 6.8.2-4 - Unbundle libxml and libxslt @@ -759,7 +961,7 @@ done - 6.7.0 * Sun Mar 3 2024 Marie Loise Nolden - 6.6.2-3 -- move qt designer plugin to -devel +- move qt designer plugin to -devel - remove old doc package code (docs are in qt6-doc) * Mon Feb 19 2024 Jan Grulich - 6.6.2-2 diff --git a/qtwebengine-6.7-ppc64.patch b/qtwebengine-6.7-ppc64.patch deleted file mode 100644 index 4079f06..0000000 --- a/qtwebengine-6.7-ppc64.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up qtwebengine-everywhere-src-6.7.2/cmake/Functions.cmake.orig qtwebengine-everywhere-src-6.7.2/cmake/Functions.cmake ---- qtwebengine-everywhere-src-6.7.2/cmake/Functions.cmake.orig 2024-09-19 16:19:27.740234419 +0200 -+++ qtwebengine-everywhere-src-6.7.2/cmake/Functions.cmake 2024-09-19 16:28:30.744377245 +0200 -@@ -635,6 +635,8 @@ function(get_gn_arch result arch) - set(${result} "mips64el" PARENT_SCOPE) - elseif(arch STREQUAL "riscv64") - set(${result} "riscv64" PARENT_SCOPE) -+ elseif(arch STREQUAL "power64") -+ set(${result} "ppc64" PARENT_SCOPE) - else() - message(FATAL_ERROR "Unknown architecture: ${arch}") - endif() diff --git a/qtwebengine-6.9-ppc64.patch b/qtwebengine-6.9-ppc64.patch new file mode 100644 index 0000000..8b58211 --- /dev/null +++ b/qtwebengine-6.9-ppc64.patch @@ -0,0 +1,13 @@ +diff --git a/cmake/QtToolchainHelpers.cmake b/cmake/QtToolchainHelpers.cmake +index eaa3a4339..5693c4cc4 100644 +--- a/cmake/QtToolchainHelpers.cmake ++++ b/cmake/QtToolchainHelpers.cmake +@@ -55,6 +55,8 @@ function(get_gn_arch result arch) + set(${result} "mips64el" PARENT_SCOPE) + elseif(arch STREQUAL "riscv64") + set(${result} "riscv64" PARENT_SCOPE) ++ elseif(arch STREQUAL "power64") ++ set(${result} "ppc64" PARENT_SCOPE) + else() + message(FATAL_ERROR "Unknown architecture: ${arch}") + endif() diff --git a/qtwebengine-add-missing-pipewire-headers.patch b/qtwebengine-add-missing-pipewire-headers.patch new file mode 100644 index 0000000..d30ab52 --- /dev/null +++ b/qtwebengine-add-missing-pipewire-headers.patch @@ -0,0 +1,57 @@ +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/qtwebengine-chromium-141-glibc-2.42-SYS_SECCOMP.patch b/qtwebengine-chromium-141-glibc-2.42-SYS_SECCOMP.patch new file mode 100644 index 0000000..6c827bc --- /dev/null +++ b/qtwebengine-chromium-141-glibc-2.42-SYS_SECCOMP.patch @@ -0,0 +1,29 @@ +Fix FTBFS + +/usr/include/bits/siginfo-consts.h:219:3: error: expected identifier + 219 | SYS_SECCOMP = 1, /* Seccomp triggered. */ + | ^ +../../sandbox/linux/system_headers/linux_seccomp.h:220:39: note: expanded from macro 'SYS_SECCOMP' + 220 | #define SYS_SECCOMP 1 + | ^ +../../sandbox/linux/seccomp-bpf/trap.cc:159:46: error: use of undeclared identifier 'SYS_SECCOMP' + 159 | if (nr != LINUX_SIGSYS || info->si_code != SYS_SECCOMP || !ctx || + | ^~~~~~~~~~~ +/usr/include/bits/siginfo-consts.h:220:23: note: expanded from macro 'SYS_SECCOMP' + 220 | # define SYS_SECCOMP SYS_SECCOMP + +diff -up chromium-141.0.7390.122/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h.me chromium-141.0.7390.122/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h +--- chromium-141.0.7390.122/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h.me 2025-10-28 10:05:44.970248151 +0100 ++++ chromium-141.0.7390.122/src/3rdparty/chromium/sandbox/linux/system_headers/linux_seccomp.h 2025-10-28 10:05:52.291345772 +0100 +@@ -214,8 +214,11 @@ struct seccomp_notif_addfd { + #define SECCOMP_RET_INVALID 0x00010000U // Illegal return value + #endif + ++// check glibc version < 2.42 ++#if (__GLIBC__ < 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 42) + #ifndef SYS_SECCOMP + #define SYS_SECCOMP 1 + #endif ++#endif + + #endif // SANDBOX_LINUX_SYSTEM_HEADERS_LINUX_SECCOMP_H_ diff --git a/qtwebengine-chromium-ppc64-highway.patch b/qtwebengine-chromium-ppc64-highway.patch new file mode 100644 index 0000000..7bc3e06 --- /dev/null +++ b/qtwebengine-chromium-ppc64-highway.patch @@ -0,0 +1,258 @@ +commit dcc0ca1cd4245ecff9e5ba50818e47d5e2ccf699 +Author: John Platts +Date: Fri Jan 17 12:16:49 2025 -0600 + + Fix for GCC 15 compiler error on PPC8/PPC9/PPC10 + +diff --git a/hwy/ops/ppc_vsx-inl.h b/hwy/ops/ppc_vsx-inl.h +index 86d6d98c..3564ae0b 100644 +--- a/hwy/ops/ppc_vsx-inl.h ++++ b/hwy/ops/ppc_vsx-inl.h +@@ -3744,16 +3744,73 @@ static HWY_INLINE V VsxF2INormalizeSrcVals(V v) { + #endif + } + ++template ++static HWY_INLINE HWY_MAYBE_UNUSED VFromD>> ++VsxXvcvspsxds(VF32 vf32) { ++ using VI64 = VFromD>>; ++#if (HWY_COMPILER_GCC_ACTUAL && HWY_COMPILER_GCC_ACTUAL < 1500) || \ ++ HWY_HAS_BUILTIN(__builtin_vsx_xvcvspsxds) ++ // Use __builtin_vsx_xvcvspsxds if it is available (which is the case with ++ // GCC 4.8 through GCC 14 or Clang 13 or later on PPC8/PPC9/PPC10) ++ return VI64{__builtin_vsx_xvcvspsxds(vf32.raw)}; ++#elif HWY_COMPILER_GCC_ACTUAL >= 1500 && HWY_IS_LITTLE_ENDIAN ++ // On little-endian PPC8/PPC9/PPC10 with GCC 15 or later, use the F32->I64 ++ // vec_signedo intrinsic as the __builtin_vsx_xvcvspsxds intrinsic has been ++ // removed from GCC in GCC 15 ++ return VI64{vec_signedo(vf32.raw)}; ++#elif HWY_COMPILER_GCC_ACTUAL >= 1500 && HWY_IS_BIG_ENDIAN ++ // On big-endian PPC8/PPC9/PPC10 with GCC 15 or later, use the F32->I64 ++ // vec_signede intrinsic as the __builtin_vsx_xvcvspsxds intrinsic has been ++ // removed from GCC in GCC 15 ++ return VI64{vec_signede(vf32.raw)}; ++#else ++ // Inline assembly fallback for older versions of Clang that do not have the ++ // __builtin_vsx_xvcvspsxds intrinsic ++ __vector signed long long raw_result; ++ __asm__("xvcvspsxds %x0, %x1" : "=wa"(raw_result) : "wa"(vf32.raw) :); ++ return VI64{raw_result}; ++#endif ++} ++ ++template ++static HWY_INLINE HWY_MAYBE_UNUSED VFromD>> ++VsxXvcvspuxds(VF32 vf32) { ++ using VU64 = VFromD>>; ++#if (HWY_COMPILER_GCC_ACTUAL && HWY_COMPILER_GCC_ACTUAL < 1500) || \ ++ HWY_HAS_BUILTIN(__builtin_vsx_xvcvspuxds) ++ // Use __builtin_vsx_xvcvspuxds if it is available (which is the case with ++ // GCC 4.8 through GCC 14 or Clang 13 or later on PPC8/PPC9/PPC10) ++ return VU64{reinterpret_cast<__vector unsigned long long>( ++ __builtin_vsx_xvcvspuxds(vf32.raw))}; ++#elif HWY_COMPILER_GCC_ACTUAL >= 1500 && HWY_IS_LITTLE_ENDIAN ++ // On little-endian PPC8/PPC9/PPC10 with GCC 15 or later, use the F32->U64 ++ // vec_unsignedo intrinsic as the __builtin_vsx_xvcvspuxds intrinsic has been ++ // removed from GCC in GCC 15 ++ return VU64{vec_unsignedo(vf32.raw)}; ++#elif HWY_COMPILER_GCC_ACTUAL >= 1500 && HWY_IS_BIG_ENDIAN ++ // On big-endian PPC8/PPC9/PPC10 with GCC 15 or later, use the F32->U64 ++ // vec_unsignedo intrinsic as the __builtin_vsx_xvcvspuxds intrinsic has been ++ // removed from GCC in GCC 15 ++ return VU64{vec_unsignede(vf32.raw)}; ++#else ++ // Inline assembly fallback for older versions of Clang that do not have the ++ // __builtin_vsx_xvcvspuxds intrinsic ++ __vector unsigned long long raw_result; ++ __asm__("xvcvspuxds %x0, %x1" : "=wa"(raw_result) : "wa"(vf32.raw) :); ++ return VU64{raw_result}; ++#endif ++} ++ + } // namespace detail + #endif // !HWY_S390X_HAVE_Z14 + + template + HWY_API VFromD PromoteTo(D di64, VFromD> v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspsxds)) +- const __vector float raw_v = +- detail::VsxF2INormalizeSrcVals(InterleaveLower(v, v)).raw; +- return VFromD{__builtin_vsx_xvcvspsxds(raw_v)}; ++#if !HWY_S390X_HAVE_Z14 ++ const Repartition dt_f32; ++ const auto vt_f32 = ResizeBitCast(dt_f32, v); ++ return detail::VsxXvcvspsxds( ++ detail::VsxF2INormalizeSrcVals(InterleaveLower(vt_f32, vt_f32))); + #else + const RebindToFloat df64; + return ConvertTo(di64, PromoteTo(df64, v)); +@@ -3762,12 +3819,11 @@ HWY_API VFromD PromoteTo(D di64, VFromD> v) { + + template + HWY_API VFromD PromoteTo(D du64, VFromD> v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspuxds)) +- const __vector float raw_v = +- detail::VsxF2INormalizeSrcVals(InterleaveLower(v, v)).raw; +- return VFromD{reinterpret_cast<__vector unsigned long long>( +- __builtin_vsx_xvcvspuxds(raw_v))}; ++#if !HWY_S390X_HAVE_Z14 ++ const Repartition dt_f32; ++ const auto vt_f32 = ResizeBitCast(dt_f32, v); ++ return detail::VsxXvcvspuxds( ++ detail::VsxF2INormalizeSrcVals(InterleaveLower(vt_f32, vt_f32))); + #else + const RebindToFloat df64; + return ConvertTo(du64, PromoteTo(df64, v)); +@@ -3876,12 +3932,10 @@ HWY_API VFromD PromoteUpperTo(D df64, Vec128 v) { + + template + HWY_API VFromD PromoteUpperTo(D di64, Vec128 v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspsxds)) +- const __vector float raw_v = +- detail::VsxF2INormalizeSrcVals(InterleaveUpper(Full128(), v, v)) +- .raw; +- return VFromD{__builtin_vsx_xvcvspsxds(raw_v)}; ++#if !HWY_S390X_HAVE_Z14 ++ (void)di64; ++ return detail::VsxXvcvspsxds( ++ detail::VsxF2INormalizeSrcVals(InterleaveUpper(Full128(), v, v))); + #else + const RebindToFloat df64; + return ConvertTo(di64, PromoteUpperTo(df64, v)); +@@ -3890,13 +3944,10 @@ HWY_API VFromD PromoteUpperTo(D di64, Vec128 v) { + + template + HWY_API VFromD PromoteUpperTo(D du64, Vec128 v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspuxds)) +- const __vector float raw_v = +- detail::VsxF2INormalizeSrcVals(InterleaveUpper(Full128(), v, v)) +- .raw; +- return VFromD{reinterpret_cast<__vector unsigned long long>( +- __builtin_vsx_xvcvspuxds(raw_v))}; ++#if !HWY_S390X_HAVE_Z14 ++ (void)du64; ++ return detail::VsxXvcvspuxds( ++ detail::VsxF2INormalizeSrcVals(InterleaveUpper(Full128(), v, v))); + #else + const RebindToFloat df64; + return ConvertTo(du64, PromoteUpperTo(df64, v)); +@@ -3984,20 +4035,18 @@ HWY_INLINE VFromD PromoteEvenTo(hwy::SignedTag /*to_type_tag*/, + hwy::SizeTag<8> /*to_lane_size_tag*/, + hwy::FloatTag /*from_type_tag*/, D d_to, + V v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspsxds)) ++#if !HWY_S390X_HAVE_Z14 + (void)d_to; + const auto normalized_v = detail::VsxF2INormalizeSrcVals(v); + #if HWY_IS_LITTLE_ENDIAN +- // __builtin_vsx_xvcvspsxds expects the source values to be in the odd lanes +- // on little-endian PPC, and the vec_sld operation below will shift the even ++ // VsxXvcvspsxds expects the source values to be in the odd lanes on ++ // little-endian PPC, and the Shuffle2103 operation below will shift the even + // lanes of normalized_v into the odd lanes. +- return VFromD{ +- __builtin_vsx_xvcvspsxds(vec_sld(normalized_v.raw, normalized_v.raw, 4))}; ++ return VsxXvcvspsxds(Shuffle2103(normalized_v)); + #else +- // __builtin_vsx_xvcvspsxds expects the source values to be in the even lanes +- // on big-endian PPC. +- return VFromD{__builtin_vsx_xvcvspsxds(normalized_v.raw)}; ++ // VsxXvcvspsxds expects the source values to be in the even lanes on ++ // big-endian PPC. ++ return VsxXvcvspsxds(normalized_v); + #endif + #else + const RebindToFloat df64; +@@ -4012,22 +4061,18 @@ HWY_INLINE VFromD PromoteEvenTo(hwy::UnsignedTag /*to_type_tag*/, + hwy::SizeTag<8> /*to_lane_size_tag*/, + hwy::FloatTag /*from_type_tag*/, D d_to, + V v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspuxds)) ++#if !HWY_S390X_HAVE_Z14 + (void)d_to; + const auto normalized_v = detail::VsxF2INormalizeSrcVals(v); + #if HWY_IS_LITTLE_ENDIAN +- // __builtin_vsx_xvcvspuxds expects the source values to be in the odd lanes +- // on little-endian PPC, and the vec_sld operation below will shift the even +- // lanes of normalized_v into the odd lanes. +- return VFromD{ +- reinterpret_cast<__vector unsigned long long>(__builtin_vsx_xvcvspuxds( +- vec_sld(normalized_v.raw, normalized_v.raw, 4)))}; ++ // VsxXvcvspuxds expects the source values to be in the odd lanes ++ // on little-endian PPC, and the Shuffle2103 operation below will shift the ++ // even lanes of normalized_v into the odd lanes. ++ return VsxXvcvspuxds(Shuffle2103(normalized_v)); + #else +- // __builtin_vsx_xvcvspuxds expects the source values to be in the even lanes ++ // VsxXvcvspuxds expects the source values to be in the even lanes + // on big-endian PPC. +- return VFromD{reinterpret_cast<__vector unsigned long long>( +- __builtin_vsx_xvcvspuxds(normalized_v.raw))}; ++ return VsxXvcvspuxds(normalized_v); + #endif + #else + const RebindToFloat df64; +@@ -4069,20 +4114,18 @@ HWY_INLINE VFromD PromoteOddTo(hwy::SignedTag /*to_type_tag*/, + hwy::SizeTag<8> /*to_lane_size_tag*/, + hwy::FloatTag /*from_type_tag*/, D d_to, + V v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspsxds)) ++#if !HWY_S390X_HAVE_Z14 + (void)d_to; + const auto normalized_v = detail::VsxF2INormalizeSrcVals(v); + #if HWY_IS_LITTLE_ENDIAN +- // __builtin_vsx_xvcvspsxds expects the source values to be in the odd lanes ++ // VsxXvcvspsxds expects the source values to be in the odd lanes + // on little-endian PPC +- return VFromD{__builtin_vsx_xvcvspsxds(normalized_v.raw)}; ++ return VsxXvcvspsxds(normalized_v); + #else +- // __builtin_vsx_xvcvspsxds expects the source values to be in the even lanes +- // on big-endian PPC, and the vec_sld operation below will shift the odd lanes +- // of normalized_v into the even lanes. +- return VFromD{ +- __builtin_vsx_xvcvspsxds(vec_sld(normalized_v.raw, normalized_v.raw, 4))}; ++ // VsxXvcvspsxds expects the source values to be in the even lanes ++ // on big-endian PPC, and the Shuffle0321 operation below will shift the odd ++ // lanes of normalized_v into the even lanes. ++ return VsxXvcvspsxds(Shuffle0321(normalized_v)); + #endif + #else + const RebindToFloat df64; +@@ -4097,22 +4140,18 @@ HWY_INLINE VFromD PromoteOddTo(hwy::UnsignedTag /*to_type_tag*/, + hwy::SizeTag<8> /*to_lane_size_tag*/, + hwy::FloatTag /*from_type_tag*/, D d_to, + V v) { +-#if !HWY_S390X_HAVE_Z14 && \ +- (HWY_COMPILER_GCC_ACTUAL || HWY_HAS_BUILTIN(__builtin_vsx_xvcvspuxds)) ++#if !HWY_S390X_HAVE_Z14 + (void)d_to; + const auto normalized_v = detail::VsxF2INormalizeSrcVals(v); + #if HWY_IS_LITTLE_ENDIAN +- // __builtin_vsx_xvcvspuxds expects the source values to be in the odd lanes ++ // VsxXvcvspuxds expects the source values to be in the odd lanes + // on little-endian PPC +- return VFromD{reinterpret_cast<__vector unsigned long long>( +- __builtin_vsx_xvcvspuxds(normalized_v.raw))}; ++ return VsxXvcvspuxds(normalized_v); + #else +- // __builtin_vsx_xvcvspuxds expects the source values to be in the even lanes +- // on big-endian PPC, and the vec_sld operation below will shift the odd lanes +- // of normalized_v into the even lanes. +- return VFromD{ +- reinterpret_cast<__vector unsigned long long>(__builtin_vsx_xvcvspuxds( +- vec_sld(normalized_v.raw, normalized_v.raw, 4)))}; ++ // VsxXvcvspuxds expects the source values to be in the even lanes ++ // on big-endian PPC, and the Shuffle0321 operation below will shift the odd ++ // lanes of normalized_v into the even lanes. ++ return VsxXvcvspuxds(Shuffle0321(normalized_v)); + #endif + #else + const RebindToFloat df64; diff --git a/qtwebengine-chromium-ppc64.patch b/qtwebengine-chromium-ppc64.patch index 474ef7c..623447f 100644 --- a/qtwebengine-chromium-ppc64.patch +++ b/qtwebengine-chromium-ppc64.patch @@ -10,11 +10,11 @@ More investigation required. sandbox/linux/seccomp-bpf/trap.cc | 14 ++++++++++++++ 1 file changed, 14 insertions(+) -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf/trap.cc +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf/trap.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf/trap.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf/trap.cc -@@ -231,6 +231,20 @@ void Trap::SigSys(int nr, LinuxSigInfo* +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf/trap.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf/trap.cc +@@ -236,6 +236,20 @@ void Trap::SigSys(int nr, LinuxSigInfo* SetIsInSigHandler(); } @@ -44,10 +44,10 @@ Subject: [PATCH 1/1] sandbox: Enable seccomp_bpf for ppc64 sandbox/features.gni | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -Index: chromium-122.0.6261.128/sandbox/features.gni +Index: chromium-134.0.6998.35/sandbox/features.gni =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/features.gni -+++ chromium-122.0.6261.128/sandbox/features.gni +--- chromium-134.0.6998.35.orig/sandbox/features.gni ++++ chromium-134.0.6998.35/sandbox/features.gni @@ -9,7 +9,8 @@ use_seccomp_bpf = (is_linux || is_chromeos || is_android) && (current_cpu == "x86" || current_cpu == "x64" || @@ -68,11 +68,11 @@ Subject: [PATCH] services/service_manager/sandbox/linux: Fix TCGETS .../sandbox/linux/bpf_renderer_policy_linux.cc | 5 +++++ 1 file changed, 5 insertions(+) -Index: chromium-122.0.6261.128/sandbox/policy/linux/bpf_renderer_policy_linux.cc +Index: chromium-134.0.6998.35/sandbox/policy/linux/bpf_renderer_policy_linux.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/policy/linux/bpf_renderer_policy_linux.cc -+++ chromium-122.0.6261.128/sandbox/policy/linux/bpf_renderer_policy_linux.cc -@@ -15,6 +15,11 @@ +--- chromium-134.0.6998.35.orig/sandbox/policy/linux/bpf_renderer_policy_linux.cc ++++ chromium-134.0.6998.35/sandbox/policy/linux/bpf_renderer_policy_linux.cc +@@ -17,6 +17,11 @@ #include "sandbox/linux/system_headers/linux_syscalls.h" #include "sandbox/policy/linux/sandbox_linux.h" @@ -93,10 +93,10 @@ Subject: [PATCH 1/4] sandbox/linux/bpf_dsl: Update syscall ranges for ppc64 sandbox/linux/bpf_dsl/linux_syscall_ranges.h | 7 +++++++ 1 file changed, 7 insertions(+) -Index: chromium-122.0.6261.128/sandbox/linux/bpf_dsl/linux_syscall_ranges.h +Index: chromium-134.0.6998.35/sandbox/linux/bpf_dsl/linux_syscall_ranges.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/bpf_dsl/linux_syscall_ranges.h -+++ chromium-122.0.6261.128/sandbox/linux/bpf_dsl/linux_syscall_ranges.h +--- chromium-134.0.6998.35.orig/sandbox/linux/bpf_dsl/linux_syscall_ranges.h ++++ chromium-134.0.6998.35/sandbox/linux/bpf_dsl/linux_syscall_ranges.h @@ -56,6 +56,13 @@ #define MAX_PUBLIC_SYSCALL __NR_syscalls #define MAX_SYSCALL MAX_PUBLIC_SYSCALL @@ -130,11 +130,11 @@ GNU/Linux environments, but may require expansion elsewhere. create mode 100644 sandbox/linux/system_headers/ppc64_linux_syscalls.h create mode 100644 sandbox/linux/system_headers/ppc64_linux_ucontext.h -Index: chromium-122.0.6261.128/sandbox/linux/BUILD.gn +Index: chromium-134.0.6998.35/sandbox/linux/BUILD.gn =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/BUILD.gn -+++ chromium-122.0.6261.128/sandbox/linux/BUILD.gn -@@ -383,6 +383,8 @@ component("sandbox_services") { +--- chromium-134.0.6998.35.orig/sandbox/linux/BUILD.gn ++++ chromium-134.0.6998.35/sandbox/linux/BUILD.gn +@@ -384,6 +384,8 @@ component("sandbox_services") { source_set("sandbox_services_headers") { sources = [ @@ -143,10 +143,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/BUILD.gn "system_headers/arm64_linux_syscalls.h", "system_headers/arm_linux_syscalls.h", "system_headers/arm_linux_ucontext.h", -Index: chromium-122.0.6261.128/sandbox/linux/system_headers/linux_syscalls.h +Index: chromium-134.0.6998.35/sandbox/linux/system_headers/linux_syscalls.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/system_headers/linux_syscalls.h -+++ chromium-122.0.6261.128/sandbox/linux/system_headers/linux_syscalls.h +--- chromium-134.0.6998.35.orig/sandbox/linux/system_headers/linux_syscalls.h ++++ chromium-134.0.6998.35/sandbox/linux/system_headers/linux_syscalls.h @@ -35,5 +35,9 @@ #include "sandbox/linux/system_headers/arm64_linux_syscalls.h" #endif @@ -157,10 +157,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/system_headers/linux_syscalls.h + #endif // SANDBOX_LINUX_SYSTEM_HEADERS_LINUX_SYSCALLS_H_ -Index: chromium-122.0.6261.128/sandbox/linux/system_headers/ppc64_linux_syscalls.h +Index: chromium-134.0.6998.35/sandbox/linux/system_headers/ppc64_linux_syscalls.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/sandbox/linux/system_headers/ppc64_linux_syscalls.h ++++ chromium-134.0.6998.35/sandbox/linux/system_headers/ppc64_linux_syscalls.h @@ -0,0 +1,12 @@ +// Copyright 2014 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be @@ -174,10 +174,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/system_headers/ppc64_linux_syscalls +//TODO: is it necessary to redefine syscall numbers for PPC64? + +#endif // SANDBOX_LINUX_SYSTEM_HEADERS_PPC64_LINUX_SYSCALLS_H_ -Index: chromium-122.0.6261.128/sandbox/linux/system_headers/ppc64_linux_ucontext.h +Index: chromium-134.0.6998.35/sandbox/linux/system_headers/ppc64_linux_ucontext.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/sandbox/linux/system_headers/ppc64_linux_ucontext.h ++++ chromium-134.0.6998.35/sandbox/linux/system_headers/ppc64_linux_ucontext.h @@ -0,0 +1,12 @@ +// Copyright 2014 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be @@ -200,11 +200,11 @@ Subject: [PATCH] sandbox/linux: Update IsSyscallAllowed in broker_process.cc sandbox/linux/syscall_broker/broker_process.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -Index: chromium-122.0.6261.128/sandbox/linux/syscall_broker/broker_process.cc +Index: chromium-134.0.6998.35/sandbox/linux/syscall_broker/broker_process.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/syscall_broker/broker_process.cc -+++ chromium-122.0.6261.128/sandbox/linux/syscall_broker/broker_process.cc -@@ -169,7 +169,7 @@ bool BrokerProcess::IsSyscallBrokerable( +--- chromium-134.0.6998.35.orig/sandbox/linux/syscall_broker/broker_process.cc ++++ chromium-134.0.6998.35/sandbox/linux/syscall_broker/broker_process.cc +@@ -168,7 +168,7 @@ bool BrokerProcess::IsSyscallBrokerable( #if defined(__NR_fstatat64) case __NR_fstatat64: #endif @@ -227,10 +227,10 @@ Subject: [PATCH] sandbox/linux: Update syscall helpers/lists for ppc64 sandbox/linux/services/syscall_wrappers.cc | 2 +- 6 files changed, 73 insertions(+), 55 deletions(-) -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/baseline_policy.cc @@ -90,7 +90,8 @@ bool IsBaselinePolicyWatched(int sysno) SyscallSets::IsPrctl(sysno) || SyscallSets::IsProcessGroupOrSession(sysno) || @@ -269,19 +269,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/baseline_policy if (SyscallSets::IsSocketCall(sysno)) return RestrictSocketcallCommand(); #endif -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc -@@ -36,7 +36,7 @@ - #include "sandbox/linux/system_headers/linux_time.h" - - #if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \ -- !defined(__arm__) && !defined(__aarch64__) && \ -+ !defined(__arm__) && !defined(__aarch64__) && !defined(__powerpc64__) && \ - !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. +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc @@ -45,6 +45,11 @@ #include #endif @@ -352,7 +343,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_paramet ResultExpr RestrictSocketcallCommand() { // Unfortunately, we are unable to restrict the first parameter to // socketpair(2). Whilst initially sounding bad, it's noteworthy that very -@@ -463,7 +488,7 @@ ResultExpr RestrictPtrace() { +@@ -461,7 +486,7 @@ ResultExpr RestrictPtrace() { #endif return Switch(request) .Cases({ @@ -361,10 +352,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_paramet PTRACE_GETREGS, PTRACE_GETFPREGS, PTRACE_GET_THREAD_AREA, PTRACE_GETREGSET, #endif -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.h @@ -52,7 +52,7 @@ SANDBOX_EXPORT bpf_dsl::ResultExpr Restr // O_NONBLOCK | O_SYNC | O_LARGEFILE | O_CLOEXEC | O_NOATIME. SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictFcntlCommands(); @@ -374,10 +365,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_paramet // Restrict socketcall(2) to only allow socketpair(2), send(2), recv(2), // sendto(2), recvfrom(2), shutdown(2), sendmsg(2) and recvmsg(2). SANDBOX_EXPORT bpf_dsl::ResultExpr RestrictSocketcallCommand(); -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc @@ -29,7 +29,8 @@ bool SyscallSets::IsAllowedGettime(int s switch (sysno) { case __NR_gettimeofday: @@ -572,7 +563,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc bool SyscallSets::IsNetworkSocketInformation(int sysno) { switch (sysno) { case __NR_getpeername: -@@ -553,7 +567,7 @@ bool SyscallSets::IsAllowedAddressSpaceA +@@ -554,7 +568,7 @@ bool SyscallSets::IsAllowedAddressSpaceA case __NR_mincore: case __NR_mlockall: #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -581,7 +572,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_mmap: #endif #if defined(__i386__) || defined(__arm__) || \ -@@ -583,7 +597,8 @@ bool SyscallSets::IsAllowedGeneralIo(int +@@ -584,7 +598,8 @@ bool SyscallSets::IsAllowedGeneralIo(int switch (sysno) { case __NR_lseek: #if defined(__i386__) || defined(__arm__) || \ @@ -591,42 +582,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR__llseek: #endif #if !defined(__aarch64__) -@@ -603,26 +618,28 @@ bool SyscallSets::IsAllowedGeneralIo(int - case __NR_readv: - case __NR_pread64: - #if defined(__arm__) || \ -- (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) -+ (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \ -+ defined(__powerpc64__) - case __NR_recv: - #endif - #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \ -- defined(__aarch64__) -+ defined(__aarch64__) || defined(__powerpc64__) - case __NR_recvfrom: // Could specify source. - case __NR_recvmsg: // Could specify source. - #endif --#if defined(__i386__) || defined(__x86_64__) -+#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__) - case __NR_select: - #endif --#if defined(__i386__) || defined(__arm__) || defined(__mips__) -+#if defined(__i386__) || defined(__arm__) || defined(__mips__) || defined(__powerpc64__) - case __NR__newselect: - #endif - #if defined(__arm__) || \ -- (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) -+ (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \ -+ defined(__powerpc64__) - case __NR_send: - #endif - #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \ -- defined(__aarch64__) -+ defined(__aarch64__) || defined(__powerpc64__) - case __NR_sendmsg: // Could specify destination. - case __NR_sendto: // Could specify destination. - #endif -@@ -678,7 +695,8 @@ bool SyscallSets::IsAllowedBasicSchedule +@@ -679,7 +696,8 @@ bool SyscallSets::IsAllowedBasicSchedule return true; case __NR_getpriority: #if defined(__i386__) || defined(__arm__) || \ @@ -636,7 +592,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_nice: #endif case __NR_setpriority: -@@ -690,7 +708,8 @@ bool SyscallSets::IsAllowedBasicSchedule +@@ -691,7 +709,8 @@ bool SyscallSets::IsAllowedBasicSchedule bool SyscallSets::IsAdminOperation(int sysno) { switch (sysno) { #if defined(__i386__) || defined(__arm__) || \ @@ -646,7 +602,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_bdflush: #endif case __NR_kexec_load: -@@ -706,7 +725,8 @@ bool SyscallSets::IsAdminOperation(int s +@@ -707,7 +726,8 @@ bool SyscallSets::IsAdminOperation(int s bool SyscallSets::IsKernelModule(int sysno) { switch (sysno) { @@ -656,7 +612,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_create_module: case __NR_get_kernel_syms: // Should ENOSYS. case __NR_query_module: -@@ -739,7 +759,8 @@ bool SyscallSets::IsFsControl(int sysno) +@@ -740,7 +760,8 @@ bool SyscallSets::IsFsControl(int sysno) case __NR_swapoff: case __NR_swapon: #if defined(__i386__) || \ @@ -666,7 +622,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_umount: #endif case __NR_umount2: -@@ -755,7 +776,7 @@ bool SyscallSets::IsNuma(int sysno) { +@@ -756,7 +777,7 @@ bool SyscallSets::IsNuma(int sysno) { case __NR_getcpu: case __NR_mbind: #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -675,7 +631,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_migrate_pages: #endif case __NR_move_pages: -@@ -790,14 +811,15 @@ bool SyscallSets::IsGlobalProcessEnviron +@@ -791,14 +812,15 @@ bool SyscallSets::IsGlobalProcessEnviron switch (sysno) { case __NR_acct: // Privileged. #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -694,7 +650,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_ulimit: #endif case __NR_getrusage: -@@ -831,7 +853,7 @@ bool SyscallSets::IsGlobalSystemStatus(i +@@ -832,7 +854,7 @@ bool SyscallSets::IsGlobalSystemStatus(i #endif case __NR_sysinfo: case __NR_uname: @@ -703,7 +659,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_olduname: case __NR_oldolduname: #endif -@@ -915,7 +937,8 @@ bool SyscallSets::IsSystemVSemaphores(in +@@ -916,7 +938,8 @@ bool SyscallSets::IsSystemVSemaphores(in #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \ defined(__aarch64__) || \ @@ -713,7 +669,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc // These give a lot of ambient authority and bypass the setuid sandbox. bool SyscallSets::IsSystemVSharedMemory(int sysno) { switch (sysno) { -@@ -946,7 +969,8 @@ bool SyscallSets::IsSystemVMessageQueue( +@@ -947,7 +970,8 @@ bool SyscallSets::IsSystemVMessageQueue( #endif #if defined(__i386__) || \ @@ -723,7 +679,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc // Big system V multiplexing system call. bool SyscallSets::IsSystemVIpc(int sysno) { switch (sysno) { -@@ -966,7 +990,8 @@ bool SyscallSets::IsAnySystemV(int sysno +@@ -967,7 +991,8 @@ bool SyscallSets::IsAnySystemV(int sysno return IsSystemVMessageQueue(sysno) || IsSystemVSemaphores(sysno) || IsSystemVSharedMemory(sysno); #elif defined(__i386__) || \ @@ -733,7 +689,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc return IsSystemVIpc(sysno); #endif } -@@ -1023,7 +1048,8 @@ bool SyscallSets::IsFaNotify(int sysno) +@@ -1024,7 +1049,8 @@ bool SyscallSets::IsFaNotify(int sysno) bool SyscallSets::IsTimer(int sysno) { switch (sysno) { case __NR_getitimer: @@ -743,7 +699,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_alarm: #endif case __NR_setitimer: -@@ -1102,18 +1128,22 @@ bool SyscallSets::IsMisc(int sysno) { +@@ -1103,18 +1129,22 @@ bool SyscallSets::IsMisc(int sysno) { case __NR_syncfs: case __NR_vhangup: // The system calls below are not implemented. @@ -770,7 +726,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_gtty: case __NR_idle: case __NR_lock: -@@ -1121,20 +1151,22 @@ bool SyscallSets::IsMisc(int sysno) { +@@ -1122,20 +1152,22 @@ bool SyscallSets::IsMisc(int sysno) { case __NR_prof: case __NR_profil: #endif @@ -797,10 +753,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_vserver: #endif return true; -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h @@ -46,13 +46,14 @@ class SANDBOX_EXPORT SyscallSets { static bool IsDeniedGetOrModifySocket(int sysno); @@ -838,11 +794,11 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.h // Big system V multiplexing system call. static bool IsSystemVIpc(int sysno); #endif -Index: chromium-122.0.6261.128/sandbox/linux/services/syscall_wrappers.cc +Index: chromium-134.0.6998.35/sandbox/linux/services/syscall_wrappers.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/services/syscall_wrappers.cc -+++ chromium-122.0.6261.128/sandbox/linux/services/syscall_wrappers.cc -@@ -61,7 +61,7 @@ long sys_clone(unsigned long flags, +--- chromium-134.0.6998.35.orig/sandbox/linux/services/syscall_wrappers.cc ++++ chromium-134.0.6998.35/sandbox/linux/services/syscall_wrappers.cc +@@ -66,7 +66,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) || \ @@ -861,10 +817,10 @@ Subject: [PATCH 1/4] sandbox/linux/bpf_dsl: Modify seccomp_macros to add sandbox/linux/bpf_dsl/seccomp_macros.h | 43 ++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) -Index: chromium-122.0.6261.128/sandbox/linux/bpf_dsl/seccomp_macros.h +Index: chromium-134.0.6998.35/sandbox/linux/bpf_dsl/seccomp_macros.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/bpf_dsl/seccomp_macros.h -+++ chromium-122.0.6261.128/sandbox/linux/bpf_dsl/seccomp_macros.h +--- chromium-134.0.6998.35.orig/sandbox/linux/bpf_dsl/seccomp_macros.h ++++ chromium-134.0.6998.35/sandbox/linux/bpf_dsl/seccomp_macros.h @@ -14,6 +14,9 @@ #if defined(__mips__) // sys/user.h in eglibc misses size_t definition @@ -937,10 +893,10 @@ Subject: [PATCH 3/4] sandbox/linux/system_headers: Update linux seccomp header sandbox/linux/system_headers/linux_seccomp.h | 10 ++++++++++ 1 file changed, 10 insertions(+) -Index: chromium-122.0.6261.128/sandbox/linux/system_headers/linux_seccomp.h +Index: chromium-134.0.6998.35/sandbox/linux/system_headers/linux_seccomp.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/system_headers/linux_seccomp.h -+++ chromium-122.0.6261.128/sandbox/linux/system_headers/linux_seccomp.h +--- chromium-134.0.6998.35.orig/sandbox/linux/system_headers/linux_seccomp.h ++++ chromium-134.0.6998.35/sandbox/linux/system_headers/linux_seccomp.h @@ -38,6 +38,9 @@ #ifndef EM_AARCH64 #define EM_AARCH64 183 @@ -974,10 +930,10 @@ Subject: [PATCH 4/4] sandbox/linux/system_headers: Update linux signal header sandbox/linux/system_headers/linux_signal.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -Index: chromium-122.0.6261.128/sandbox/linux/system_headers/linux_signal.h +Index: chromium-134.0.6998.35/sandbox/linux/system_headers/linux_signal.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/system_headers/linux_signal.h -+++ chromium-122.0.6261.128/sandbox/linux/system_headers/linux_signal.h +--- chromium-134.0.6998.35.orig/sandbox/linux/system_headers/linux_signal.h ++++ chromium-134.0.6998.35/sandbox/linux/system_headers/linux_signal.h @@ -13,7 +13,7 @@ // (not undefined, but defined different values and in different memory // layouts). So, fill the gap here. @@ -996,11 +952,11 @@ Subject: [PATCH] sandbox/linux/seccomp-bpf: Add ppc64 syscall stub sandbox/linux/seccomp-bpf/syscall.cc | 53 ++++++++++++++++++++++++++-- 1 file changed, 51 insertions(+), 2 deletions(-) -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf/syscall.cc +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf/syscall.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf/syscall.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf/syscall.cc -@@ -18,7 +18,7 @@ namespace sandbox { +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf/syscall.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf/syscall.cc +@@ -23,7 +23,7 @@ namespace sandbox { namespace { #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \ @@ -1009,7 +965,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf/syscall.cc // Number that's not currently used by any Linux kernel ABIs. const int kInvalidSyscallNumber = 0x351d3; #else -@@ -308,10 +308,54 @@ asm(// We need to be able to tell the ke +@@ -313,10 +313,54 @@ asm(// We need to be able to tell the ke "2:ret\n" ".cfi_endproc\n" ".size SyscallAsm, .-SyscallAsm\n" @@ -1065,7 +1021,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf/syscall.cc extern "C" { intptr_t SyscallAsm(intptr_t nr, const intptr_t args[6]); } -@@ -425,6 +469,8 @@ intptr_t Syscall::Call(int nr, +@@ -430,6 +474,8 @@ intptr_t Syscall::Call(int nr, ret = inout; } @@ -1074,7 +1030,7 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf/syscall.cc #else #error "Unimplemented architecture" #endif -@@ -441,8 +487,18 @@ void Syscall::PutValueInUcontext(intptr_ +@@ -446,8 +492,18 @@ void Syscall::PutValueInUcontext(intptr_ // needs to be changed back. ret_val = -ret_val; SECCOMP_PARM4(ctx) = 1; @@ -1103,11 +1059,11 @@ Subject: [PATCH 5/6] sandbox/linux: update unit test for ppc64 sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc -@@ -345,8 +345,10 @@ TEST_BASELINE_SIGSYS(__NR_timer_create) +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/baseline_policy_unittest.cc +@@ -350,8 +350,10 @@ TEST_BASELINE_SIGSYS(__NR_timer_create) #if !defined(__aarch64__) TEST_BASELINE_SIGSYS(__NR_inotify_init) @@ -1118,10 +1074,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/baseline_policy #if defined(LIBC_GLIBC) && !BUILDFLAG(IS_CHROMEOS_ASH) BPF_TEST_C(BaselinePolicy, FutexEINVAL, BaselinePolicy) { -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc @@ -374,7 +374,9 @@ bool SyscallSets::IsAllowedSignalHandlin #if defined(__i386__) || defined(__arm__) || \ (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \ @@ -1132,10 +1088,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc case __NR_sigaction: case __NR_sigprocmask: case __NR_sigreturn: -Index: chromium-122.0.6261.128/sandbox/linux/system_headers/linux_stat.h +Index: chromium-134.0.6998.35/sandbox/linux/system_headers/linux_stat.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/system_headers/linux_stat.h -+++ chromium-122.0.6261.128/sandbox/linux/system_headers/linux_stat.h +--- chromium-134.0.6998.35.orig/sandbox/linux/system_headers/linux_stat.h ++++ chromium-134.0.6998.35/sandbox/linux/system_headers/linux_stat.h @@ -173,6 +173,28 @@ struct kernel_stat { unsigned int __unused4; unsigned int __unused5; @@ -1165,23 +1121,23 @@ Index: chromium-122.0.6261.128/sandbox/linux/system_headers/linux_stat.h #endif #if !defined(AT_EMPTY_PATH) -Index: chromium-122.0.6261.128/sandbox/linux/services/credentials.cc +Index: chromium-134.0.6998.35/sandbox/linux/services/credentials.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/services/credentials.cc -+++ chromium-122.0.6261.128/sandbox/linux/services/credentials.cc -@@ -80,7 +80,7 @@ bool ChrootToSafeEmptyDir() { - pid_t pid = -1; - alignas(16) char stack_buf[PTHREAD_STACK_MIN]; +--- chromium-134.0.6998.35.orig/sandbox/linux/services/credentials.cc ++++ chromium-134.0.6998.35/sandbox/linux/services/credentials.cc +@@ -87,7 +87,7 @@ bool ChrootToSafeEmptyDir() { + alignas(16) char stack_buf[PTHREAD_STACK_MIN_CONST]; + #if defined(ARCH_CPU_X86_FAMILY) || defined(ARCH_CPU_ARM_FAMILY) || \ - defined(ARCH_CPU_MIPS_FAMILY) + defined(ARCH_CPU_MIPS_FAMILY) || defined(ARCH_CPU_PPC64_FAMILY) // The stack grows downward. void* stack = stack_buf + sizeof(stack_buf); #else -Index: chromium-122.0.6261.128/sandbox/policy/linux/bpf_utility_policy_linux.cc +Index: chromium-134.0.6998.35/sandbox/policy/linux/bpf_utility_policy_linux.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/policy/linux/bpf_utility_policy_linux.cc -+++ chromium-122.0.6261.128/sandbox/policy/linux/bpf_utility_policy_linux.cc +--- chromium-134.0.6998.35.orig/sandbox/policy/linux/bpf_utility_policy_linux.cc ++++ chromium-134.0.6998.35/sandbox/policy/linux/bpf_utility_policy_linux.cc @@ -34,7 +34,7 @@ ResultExpr UtilityProcessPolicy::Evaluat case __NR_fdatasync: case __NR_fsync: @@ -1191,11 +1147,11 @@ Index: chromium-122.0.6261.128/sandbox/policy/linux/bpf_utility_policy_linux.cc case __NR_getrlimit: #endif #if defined(__i386__) || defined(__arm__) -Index: chromium-122.0.6261.128/sandbox/policy/linux/bpf_renderer_policy_linux.cc +Index: chromium-134.0.6998.35/sandbox/policy/linux/bpf_renderer_policy_linux.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/policy/linux/bpf_renderer_policy_linux.cc -+++ chromium-122.0.6261.128/sandbox/policy/linux/bpf_renderer_policy_linux.cc -@@ -87,7 +87,7 @@ ResultExpr RendererProcessPolicy::Evalua +--- chromium-134.0.6998.35.orig/sandbox/policy/linux/bpf_renderer_policy_linux.cc ++++ chromium-134.0.6998.35/sandbox/policy/linux/bpf_renderer_policy_linux.cc +@@ -90,7 +90,7 @@ ResultExpr RendererProcessPolicy::Evalua case __NR_ftruncate64: #endif #if defined(__i386__) || defined(__x86_64__) || defined(__mips__) || \ @@ -1204,10 +1160,10 @@ Index: chromium-122.0.6261.128/sandbox/policy/linux/bpf_renderer_policy_linux.cc case __NR_getrlimit: case __NR_setrlimit: // We allow setrlimit to dynamically adjust the address space limit as -Index: chromium-122.0.6261.128/sandbox/linux/bpf_dsl/linux_syscall_ranges.h +Index: chromium-134.0.6998.35/sandbox/linux/bpf_dsl/linux_syscall_ranges.h =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/bpf_dsl/linux_syscall_ranges.h -+++ chromium-122.0.6261.128/sandbox/linux/bpf_dsl/linux_syscall_ranges.h +--- chromium-134.0.6998.35.orig/sandbox/linux/bpf_dsl/linux_syscall_ranges.h ++++ chromium-134.0.6998.35/sandbox/linux/bpf_dsl/linux_syscall_ranges.h @@ -58,9 +58,9 @@ #elif defined(__powerpc64__) @@ -1220,38 +1176,37 @@ Index: chromium-122.0.6261.128/sandbox/linux/bpf_dsl/linux_syscall_ranges.h #define MAX_SYSCALL MAX_PUBLIC_SYSCALL #else -Index: chromium-122.0.6261.128/sandbox/linux/services/credentials.cc +Index: chromium-134.0.6998.35/sandbox/linux/services/credentials.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/services/credentials.cc -+++ chromium-122.0.6261.128/sandbox/linux/services/credentials.cc -@@ -89,7 +89,9 @@ bool ChrootToSafeEmptyDir() { +--- chromium-134.0.6998.35.orig/sandbox/linux/services/credentials.cc ++++ chromium-134.0.6998.35/sandbox/linux/services/credentials.cc +@@ -96,7 +96,8 @@ bool ChrootToSafeEmptyDir() { int clone_flags = CLONE_FS | LINUX_SIGCHLD; void* tls = nullptr; -#if (defined(ARCH_CPU_X86_64) || defined(ARCH_CPU_ARM_FAMILY)) && \ -+// RAJA this might be it... +#if (defined(ARCH_CPU_X86_64) || defined(ARCH_CPU_ARM_FAMILY) || \ + defined(ARCH_CPU_PPC64_FAMILY)) && \ !defined(MEMORY_SANITIZER) // Use CLONE_VM | CLONE_VFORK as an optimization to avoid copying page tables. // Since clone writes to the new child's TLS before returning, we must set a -@@ -97,6 +99,11 @@ bool ChrootToSafeEmptyDir() { +@@ -104,6 +105,11 @@ bool ChrootToSafeEmptyDir() { // glibc performs syscalls by calling a function pointer in TLS, so we do not // attempt this optimization. - // TODO(crbug.com/1247458) Broken in MSan builds after LLVM f1bb30a4956f. + // TODO(crbug.com/40196869) Broken in MSan builds after LLVM f1bb30a4956f. + // + // NOTE: Without CLONE_VM, fontconfig will attempt to reload configuration + // in every thread. Since the rendered threads are sandboxed without + // filesystem access (e.g. to /etc/fonts/fonts.conf) this will cause font -+ // configuraiton loading failures and no fonts will be displayed! ++ // configuration loading failures and no fonts will be displayed! clone_flags |= CLONE_VM | CLONE_VFORK | CLONE_SETTLS; - // PTHREAD_STACK_MIN can be dynamic in glibc2.34+, so it is not possible to -Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc + char tls_buf[PTHREAD_STACK_MIN_CONST] = {}; +Index: chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc =================================================================== ---- chromium-122.0.6261.128.orig/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc -+++ chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc -@@ -357,7 +357,16 @@ intptr_t SIGSYSFstatatHandler(const stru +--- chromium-134.0.6998.35.orig/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc ++++ chromium-134.0.6998.35/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers.cc +@@ -362,7 +362,16 @@ intptr_t SIGSYSFstatatHandler(const stru if (args.nr == __NR_fstatat_default) { if (*reinterpret_cast(args.args[1]) == '\0' && args.args[3] == static_cast(AT_EMPTY_PATH)) { @@ -1269,10 +1224,10 @@ Index: chromium-122.0.6261.128/sandbox/linux/seccomp-bpf-helpers/sigsys_handlers reinterpret_cast(args.args[2])); } return -reinterpret_cast(fs_denied_errno); -Index: chromium-122.0.6261.128/third_party/angle/src/libANGLE/Constants.h +Index: chromium-134.0.6998.35/third_party/angle/src/libANGLE/Constants.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/angle/src/libANGLE/Constants.h -+++ chromium-122.0.6261.128/third_party/angle/src/libANGLE/Constants.h +--- chromium-134.0.6998.35.orig/third_party/angle/src/libANGLE/Constants.h ++++ chromium-134.0.6998.35/third_party/angle/src/libANGLE/Constants.h @@ -9,6 +9,7 @@ #ifndef LIBANGLE_CONSTANTS_H_ #define LIBANGLE_CONSTANTS_H_ @@ -1281,52 +1236,10 @@ Index: chromium-122.0.6261.128/third_party/angle/src/libANGLE/Constants.h #include "common/platform.h" #include -Index: chromium-122.0.6261.128/third_party/boringssl/src/cmake/perlasm.cmake +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/abi_self_test.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/cmake/perlasm.cmake -+++ chromium-122.0.6261.128/third_party/boringssl/src/cmake/perlasm.cmake -@@ -17,6 +17,7 @@ function(add_perlasm_target dest src) - DEPENDS - ${src} - ${PROJECT_SOURCE_DIR}/crypto/perlasm/arm-xlate.pl -+ ${PROJECT_SOURCE_DIR}/crypto/perlasm/ppc-xlate.pl - ${PROJECT_SOURCE_DIR}/crypto/perlasm/x86_64-xlate.pl - ${PROJECT_SOURCE_DIR}/crypto/perlasm/x86asm.pl - ${PROJECT_SOURCE_DIR}/crypto/perlasm/x86gas.pl -@@ -40,6 +41,9 @@ function(perlasm var arch dest src) - add_perlasm_target("${dest}-apple.S" ${src} ios32 ${ARGN}) - add_perlasm_target("${dest}-linux.S" ${src} linux32 ${ARGN}) - append_to_parent_scope("${var}_ASM" "${dest}-apple.S" "${dest}-linux.S") -+ elseif(arch STREQUAL "ppc64le") -+ add_perlasm_target("${dest}-linux.S" ${src} linux64le) -+ append_to_parent_scope("${var}_ASM" "${dest}-linux.S") - elseif(arch STREQUAL "x86") - add_perlasm_target("${dest}-apple.S" ${src} macosx -fPIC -DOPENSSL_IA32_SSE2 ${ARGN}) - add_perlasm_target("${dest}-linux.S" ${src} elf -fPIC -DOPENSSL_IA32_SSE2 ${ARGN}) -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/CMakeLists.txt -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/CMakeLists.txt -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/CMakeLists.txt -@@ -26,6 +26,7 @@ perlasm(CRYPTO_SOURCES aarch64 cipher_ex - perlasm(CRYPTO_SOURCES aarch64 test/trampoline-armv8 test/asm/trampoline-armv8.pl) - perlasm(CRYPTO_SOURCES arm chacha/chacha-armv4 chacha/asm/chacha-armv4.pl) - perlasm(CRYPTO_SOURCES arm test/trampoline-armv4 test/asm/trampoline-armv4.pl) -+perlasm(CRYPTO_SOURCES ppc64le test/trampoline-ppc test/asm/trampoline-ppc.pl) - perlasm(CRYPTO_SOURCES x86 chacha/chacha-x86 chacha/asm/chacha-x86.pl) - perlasm(CRYPTO_SOURCES x86 test/trampoline-x86 test/asm/trampoline-x86.pl) - perlasm(CRYPTO_SOURCES x86_64 chacha/chacha-x86_64 chacha/asm/chacha-x86_64.pl) -@@ -137,6 +138,7 @@ add_library( - cpu_arm_freebsd.c - cpu_arm_linux.c - cpu_intel.c -+ cpu_ppc64le.c - crypto.c - curve25519/curve25519.c - curve25519/curve25519_64_adx.c -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/abi_self_test.cc -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/abi_self_test.cc -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/abi_self_test.cc +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/abi_self_test.cc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/abi_self_test.cc @@ -521,3 +521,289 @@ TEST(ABITest, AArch64) { CHECK_ABI_NO_UNWIND(abi_test_clobber_v15_upper); } @@ -1617,10 +1530,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/abi_self_test.cc + CHECK_ABI_NO_UNWIND(abi_test_clobber_lr); +} +#endif // OPENSSL_PPC64LE && SUPPORTS_ABI_TEST -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/cpu_ppc64le.c +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/cpu_ppc64le.cc =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/cpu_ppc64le.c ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/cpu_ppc64le.cc @@ -0,0 +1,38 @@ +/* Copyright (c) 2016, Google Inc. + * @@ -1660,38 +1573,11 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/cpu_ppc64le.c +} + +#endif // OPENSSL_PPC64LE -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/crypto.c +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/crypto.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/crypto.c -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/crypto.c -@@ -25,10 +25,12 @@ static_assert(sizeof(ossl_ssize_t) == si - "ossl_ssize_t should be the same size as size_t"); - - #if !defined(OPENSSL_NO_ASM) && !defined(OPENSSL_STATIC_ARMCAP) && \ -- (defined(OPENSSL_X86) || defined(OPENSSL_X86_64) || \ -- defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64)) --// x86, x86_64, and the ARMs need to record the result of a cpuid/getauxval call --// for the asm to work correctly, unless compiled without asm code. -+ (defined(OPENSSL_X86) || defined(OPENSSL_X86_64) || \ -+ defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64) || \ -+ defined(OPENSSL_PPC64LE)) -+// x86, x86_64, the ARMs and ppc64le need to record the result of a -+// cpuid/getauxval call for the asm to work correctly, unless compiled without -+// asm code. - #define NEED_CPUID - - #else -@@ -39,7 +41,8 @@ static_assert(sizeof(ossl_ssize_t) == si - #define BORINGSSL_NO_STATIC_INITIALIZER - #endif - --#endif // !NO_ASM && !STATIC_ARMCAP && (X86 || X86_64 || ARM || AARCH64) -+#endif // !NO_ASM && !STATIC_ARMCAP && -+ // (X86 || X86_64 || ARM || AARCH64 || PPC64LE) - - - // Our assembly does not use the GOT to reference symbols, which means -@@ -83,6 +86,10 @@ uint32_t OPENSSL_get_ia32cap(int idx) { +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/crypto.cc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/crypto.cc +@@ -67,6 +67,10 @@ uint32_t OPENSSL_get_ia32cap(int idx) { return OPENSSL_ia32cap_P[idx]; } @@ -1702,23 +1588,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/crypto.c #elif defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64) #include -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/CMakeLists.txt -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/CMakeLists.txt -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/CMakeLists.txt -@@ -19,6 +19,8 @@ perlasm(BCM_SOURCES arm sha1-armv4-large - perlasm(BCM_SOURCES arm sha256-armv4 sha/asm/sha256-armv4.pl) - perlasm(BCM_SOURCES arm sha512-armv4 sha/asm/sha512-armv4.pl) - perlasm(BCM_SOURCES arm vpaes-armv7 aes/asm/vpaes-armv7.pl) -+perlasm(BCM_SOURCES ppc64le aesp8-ppc aes/asm/aesp8-ppc.pl) -+perlasm(BCM_SOURCES ppc64le ghashp8-ppc modes/asm/ghashp8-ppc.pl) - perlasm(BCM_SOURCES x86 aesni-x86 aes/asm/aesni-x86.pl) - perlasm(BCM_SOURCES x86 bn-586 bn/asm/bn-586.pl) - perlasm(BCM_SOURCES x86 co-586 bn/asm/co-586.pl) -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/aes/asm/aesp8-ppc.pl +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/asm/aesp8-ppc.pl =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/aes/asm/aesp8-ppc.pl ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/asm/aesp8-ppc.pl @@ -0,0 +1,3809 @@ +#! /usr/bin/env perl +# Copyright 2014-2018 The OpenSSL Project Authors. All Rights Reserved. @@ -5529,12 +5402,12 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/aes/a +} + +close STDOUT or die "error closing STDOUT: $!"; -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/aes/internal.h +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/internal.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/aes/internal.h -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/aes/internal.h -@@ -59,6 +59,12 @@ OPENSSL_INLINE int vpaes_capable(void) { - OPENSSL_INLINE int vpaes_capable(void) { return CRYPTO_is_NEON_capable(); } +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/aes/internal.h ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/internal.h +@@ -82,6 +82,12 @@ inline int vpaes_capable(void) { return + inline int vpaes_capable(void) { return CRYPTO_is_NEON_capable(); } #endif +#elif defined(OPENSSL_PPC64LE) @@ -5546,23 +5419,37 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/aes/i #endif #endif // !NO_ASM -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/bcm.c +@@ -504,6 +510,13 @@ void aes_gcm_dec_kernel(const uint8_t *i + const u128 Htable[16]); + #endif + ++#elif defined(OPENSSL_PPC64LE) ++#define GHASH_ASM_PPC64LE ++#define GCM_FUNCREF ++void gcm_init_p8(u128 Htable[16], const uint64_t Xi[2]); ++void gcm_gmult_p8(uint8_t Xi[16], const u128 Htable[16]); ++void gcm_ghash_p8(uint8_t Xi[16], const u128 Htable[16], const uint8_t *inp, ++ size_t len); + #endif + #endif // OPENSSL_NO_ASM + +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/bcm.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/bcm.c -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/bcm.c -@@ -102,6 +102,7 @@ - #include "self_check/fips.c" - #include "self_check/self_check.c" - #include "service_indicator/service_indicator.c" -+#include "sha/sha1-altivec.c" - #include "sha/sha1.c" - #include "sha/sha256.c" - #include "sha/sha512.c" -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/bn/bn.c +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/bcm.cc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/bcm.cc +@@ -105,6 +105,7 @@ + #include "self_check/fips.cc.inc" + #include "self_check/self_check.cc.inc" + #include "service_indicator/service_indicator.cc.inc" ++#include "sha/sha1-altivec.cc.inc" + #include "sha/sha1.cc.inc" + #include "sha/sha256.cc.inc" + #include "sha/sha512.cc.inc" +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/bn/bn.cc.inc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/bn/bn.c -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/bn/bn.c -@@ -384,6 +384,23 @@ int bn_expand(BIGNUM *bn, size_t bits) { +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/bn/bn.cc.inc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/bn/bn.cc.inc +@@ -330,6 +330,23 @@ int bn_expand(BIGNUM *bn, size_t bits) { } int bn_resize_words(BIGNUM *bn, size_t words) { @@ -5586,11 +5473,11 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/bn/bn if ((size_t)bn->width <= words) { if (!bn_wexpand(bn, words)) { return 0; -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/cipher/e_aes.c +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/cipher/e_aes.cc.inc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/cipher/e_aes.c -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/cipher/e_aes.c -@@ -1455,6 +1455,8 @@ int EVP_has_aes_hardware(void) { +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/cipher/e_aes.cc.inc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/cipher/e_aes.cc.inc +@@ -1234,6 +1234,8 @@ int EVP_has_aes_hardware(void) { return hwaes_capable() && crypto_gcm_clmul_enabled(); #elif defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64) return hwaes_capable() && CRYPTO_is_ARMv8_PMULL_capable(); @@ -5599,10 +5486,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/ciphe #else return 0; #endif -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/asm/ghashp8-ppc.pl +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/asm/ghashp8-ppc.pl =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/asm/ghashp8-ppc.pl ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/asm/ghashp8-ppc.pl @@ -0,0 +1,671 @@ +#! /usr/bin/env perl +# Copyright 2014-2016 The OpenSSL Project Authors. All Rights Reserved. @@ -6275,11 +6162,11 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes +} + +close STDOUT or die "error closing STDOUT: $!"; # enforce flush -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/gcm.c +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/gcm.cc.inc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/modes/gcm.c -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/gcm.c -@@ -228,6 +228,13 @@ void CRYPTO_ghash_init(gmult_func *out_m +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/aes/gcm.cc.inc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/gcm.cc.inc +@@ -233,6 +233,13 @@ void CRYPTO_ghash_init(gmult_func *out_m *out_hash = gcm_ghash_neon; return; } @@ -6293,11 +6180,11 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes #endif gcm_init_nohw(out_table, H); -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/gcm_test.cc +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/gcm_test.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/modes/gcm_test.cc -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/gcm_test.cc -@@ -215,5 +215,15 @@ TEST(GCMTest, ABI) { +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/aes/gcm_test.cc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/aes/gcm_test.cc +@@ -170,5 +170,15 @@ TEST(GCMTest, ABI) { } } #endif @@ -6313,28 +6200,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes +#endif // GHASH_ASM_PPC64LE } #endif // SUPPORTS_ABI_TEST && !OPENSSL_NO_ASM -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/internal.h +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/rand/getrandom_fillin.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/modes/internal.h -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/modes/internal.h -@@ -325,6 +325,13 @@ void aes_gcm_dec_kernel(const uint8_t *i - const u128 Htable[16]); - #endif - -+#elif defined(OPENSSL_PPC64LE) -+#define GHASH_ASM_PPC64LE -+#define GCM_FUNCREF -+void gcm_init_p8(u128 Htable[16], const uint64_t Xi[2]); -+void gcm_gmult_p8(uint8_t Xi[16], const u128 Htable[16]); -+void gcm_ghash_p8(uint8_t Xi[16], const u128 Htable[16], const uint8_t *inp, -+ size_t len); - #endif - #endif // OPENSSL_NO_ASM - -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/rand/getrandom_fillin.h -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/rand/getrandom_fillin.h -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/rand/getrandom_fillin.h +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/rand/getrandom_fillin.h ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/rand/getrandom_fillin.h @@ -30,6 +30,8 @@ #define EXPECTED_NR_getrandom 278 #elif defined(OPENSSL_ARM) @@ -6344,11 +6213,11 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/rand/ #elif defined(OPENSSL_RISCV64) #define EXPECTED_NR_getrandom 278 #endif -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/rand/rand.c +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/rand/rand.cc.inc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/rand/rand.c -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/rand/rand.c -@@ -431,6 +431,11 @@ void RAND_bytes_with_additional_data(uin +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/rand/rand.cc.inc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/rand/rand.cc.inc +@@ -431,6 +431,11 @@ bcm_infallible BCM_rand_bytes_with_addit // Take a read lock around accesses to |state->drbg|. This is needed to // avoid returning bad entropy if we race with // |rand_thread_state_clear_all|. @@ -6360,21 +6229,20 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/rand/ CRYPTO_MUTEX_lock_read(&state->clear_drbg_lock); #endif if (!CTR_DRBG_reseed(&state->drbg, seed, reseed_additional_data, -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/internal.h +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/sha/internal.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/fipsmodule/sha/internal.h -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/internal.h -@@ -23,17 +23,25 @@ +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/sha/internal.h ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/sha/internal.h +@@ -23,6 +23,16 @@ extern "C" { #endif -+#if defined(OPENSSL_PPC64LE) || \ -+ (!defined(OPENSSL_NO_ASM) && (defined(OPENSSL_X86) || defined(OPENSSL_ARM))) ++#if defined(OPENSSL_PPC64LE) +// POWER has an intrinsics-based implementation of SHA-1 and thus the functions +// normally defined in assembly are available even with |OPENSSL_NO_ASM| in +// this case. -+#define SHA1_ASM -+void sha1_block_data_order(uint32_t *state, const uint8_t *in, ++#define SHA1_ASM_PPC64 ++void sha1_block_data_order_ppc64(uint32_t *state, const uint8_t *in, + size_t num_blocks); +#endif + @@ -6382,27 +6250,16 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/i // Define SHA{n}[_{variant}]_ASM if sha{n}_block_data_order[_{variant}] is // defined in assembly. - #if !defined(OPENSSL_NO_ASM) && (defined(OPENSSL_X86) || defined(OPENSSL_ARM)) - --#define SHA1_ASM - #define SHA256_ASM - #define SHA512_ASM - --void sha1_block_data_order(uint32_t *state, const uint8_t *data, -- size_t num_blocks); - void sha256_block_data_order(uint32_t *state, const uint8_t *data, - size_t num_blocks); - void sha512_block_data_order(uint64_t *state, const uint8_t *data, -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/sha1-altivec.c +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/sha/sha1-altivec.cc.inc =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/sha1-altivec.c -@@ -0,0 +1,361 @@ -+/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/sha/sha1-altivec.cc.inc +@@ -0,0 +1,369 @@ ++/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.ccom) + * All rights reserved. + * + * This package is an SSL implementation written -+ * by Eric Young (eay@cryptsoft.com). ++ * by Eric Young (eay@cryptsoft.ccom). + * The implementation was written so as to conform with Netscapes SSL. + * + * This library is free for commercial and non-commercial use as long as @@ -6410,7 +6267,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s + * apply to all code found in this distribution, be it the RC4, RSA, + * lhash, DES, etc., code; not just the SSL code. The SSL documentation + * included with this distribution is covered by the same copyright terms -+ * except that the holder is Tim Hudson (tjh@cryptsoft.com). ++ * except that the holder is Tim Hudson (tjh@cryptsoft.ccom). + * + * Copyright remains Eric Young's, and as such any Copyright notices in + * the code are not to be removed. @@ -6430,12 +6287,12 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * "This product includes cryptographic software written by -+ * Eric Young (eay@cryptsoft.com)" ++ * Eric Young (eay@cryptsoft.ccom)" + * The word 'cryptographic' can be left out if the rouines from the library + * being used are not cryptographic related :-). + * 4. If you include any Windows specific code (or a derivative thereof) from + * the apps directory (application code) you must include an acknowledgement: -+ * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" ++ * "This product includes software written by Tim Hudson (tjh@cryptsoft.ccom)" + * + * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE @@ -6457,7 +6314,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s +// Altivec-optimized SHA1 in C. This is tested on ppc64le only. +// +// References: -+// https://software.intel.com/en-us/articles/improving-the-performance-of-the-secure-hash-algorithm-1 ++// https://software.intel.ccom/en-us/articles/improving-the-performance-of-the-secure-hash-algorithm-1 +// http://arctic.org/~dean/crypto/sha1.html +// +// This code used the generic SHA-1 from OpenSSL as a basis and AltiVec @@ -6467,9 +6324,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s + +#if defined(OPENSSL_PPC64LE) + ++#if defined(__cplusplus) ++extern "C" { ++#endif ++ +#include + -+void sha1_block_data_order(uint32_t *state, const uint8_t *data, size_t num); ++void sha1_block_data_order_ppc64(uint32_t *state, const uint8_t *data, size_t num); + +static uint32_t rotate(uint32_t a, int n) { return (a << n) | (a >> (32 - n)); } + @@ -6552,7 +6413,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s + return w; +} + -+// As pointed out by Wei Dai , F() below can be simplified ++// As pointed out by Wei Dai , F() below can be simplified +// to the code in F_00_19. Wei attributes these optimisations to Peter +// Gutmann's SHS code, and he attributes it to Rich Schroeppel. #define +// F(x,y,z) (((x) & (y)) | ((~(x)) & (z))) I've just become aware of another @@ -6587,7 +6448,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s + (b) = rotate((b), 30); \ + } while (0) + -+void sha1_block_data_order(uint32_t *state, const uint8_t *data, size_t num) { ++void sha1_block_data_order_ppc64(uint32_t *state, const uint8_t *data, size_t num) { + uint32_t A, B, C, D, E, T; + + A = state[0]; @@ -6745,6 +6606,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s + } +} + ++#if defined(__cplusplus) ++} ++#endif ++ +#endif // OPENSSL_PPC64LE + +#undef K_00_19 @@ -6759,20 +6624,23 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/fipsmodule/sha/s +#undef BODY_20_39 +#undef BODY_40_59 +#undef BODY_60_79 -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/internal.h +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/internal.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/crypto/internal.h -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/internal.h -@@ -181,7 +181,7 @@ extern "C" { +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/internal.h ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/internal.h +@@ -61,8 +61,9 @@ extern "C" { + #if !defined(OPENSSL_NO_ASM) && !defined(OPENSSL_STATIC_ARMCAP) && \ + (defined(OPENSSL_X86) || defined(OPENSSL_X86_64) || \ + defined(OPENSSL_ARM) || defined(OPENSSL_AARCH64)) +-// x86, x86_64, and the ARMs need to record the result of a cpuid/getauxval call +-// for the asm to work correctly, unless compiled without asm code. ++// x86, x86_64, the ARMs, and ppc64le need to record the result of a ++// cpuid/getauxval call for the asm to work correctly, unless compiled without ++// asm code. + #define NEED_CPUID - - #if defined(OPENSSL_X86) || defined(OPENSSL_X86_64) || defined(OPENSSL_ARM) || \ -- defined(OPENSSL_AARCH64) -+ defined(OPENSSL_AARCH64) || defined(OPENSSL_PPC64LE) - // OPENSSL_cpuid_setup initializes the platform-specific feature cache. - void OPENSSL_cpuid_setup(void); - #endif -@@ -1606,6 +1606,16 @@ OPENSSL_INLINE int CRYPTO_is_ARMv8_SHA51 + // OPENSSL_cpuid_setup initializes the platform-specific feature cache. This +@@ -1402,6 +1403,16 @@ inline int CRYPTO_is_ARMv8_SHA512_capabl #endif // OPENSSL_ARM || OPENSSL_AARCH64 @@ -6789,10 +6657,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/internal.h #if defined(BORINGSSL_DISPATCH_TEST) // Runtime CPU dispatch testing support -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/perlasm/ppc-xlate.pl +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/perlasm/ppc-xlate.pl =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/perlasm/ppc-xlate.pl ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/perlasm/ppc-xlate.pl @@ -0,0 +1,320 @@ +#! /usr/bin/env perl +# Copyright 2006-2016 The OpenSSL Project Authors. All Rights Reserved. @@ -6875,7 +6743,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/perlasm/ppc-xlat + $ret; +}; +my $text = sub { -+ my $ret = ($flavour =~ /aix/) ? ".csect\t.text[PR],7" : ".text"; ++ my $ret = ($flavour =~ /aix/) ? ".ccsect\t.text[PR],7" : ".text"; + $ret = ".abiversion 2\n".$ret if ($flavour =~ /linux.*64le/); + $ret; +}; @@ -7108,16 +6976,16 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/perlasm/ppc-xlat +print <<___; +#endif // !OPENSSL_NO_ASM && __powerpc64__ && __ELF__ +#if defined(__ELF__) -+// See https://www.airs.com/blog/archives/518. ++// See https://www.airs.ccom/blog/archives/518. +.section .note.GNU-stack,"",\%progbits +#endif +___ + +close STDOUT or die "error closing STDOUT: $!"; -Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/test/asm/trampoline-ppc.pl +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/test/asm/trampoline-ppc.pl =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/crypto/test/asm/trampoline-ppc.pl ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/test/asm/trampoline-ppc.pl @@ -0,0 +1,262 @@ +#!/usr/bin/env perl +# Copyright (c) 2019, Google Inc. @@ -7381,10 +7249,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/crypto/test/asm/trampol + +print $code; +close STDOUT or die "error closing STDOUT: $!"; -Index: chromium-122.0.6261.128/third_party/boringssl/src/include/openssl/target.h +Index: chromium-134.0.6998.35/third_party/boringssl/src/include/openssl/target.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/include/openssl/target.h -+++ chromium-122.0.6261.128/third_party/boringssl/src/include/openssl/target.h +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/include/openssl/target.h ++++ chromium-134.0.6998.35/third_party/boringssl/src/include/openssl/target.h @@ -34,6 +34,9 @@ #elif defined(__ARMEL__) || defined(_M_ARM) #define OPENSSL_32_BIT @@ -7395,11 +7263,11 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/include/openssl/target. #elif defined(__MIPSEL__) && !defined(__LP64__) #define OPENSSL_32_BIT #define OPENSSL_MIPS -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/acvp/modulewrapper/main.cc +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/acvp/modulewrapper/main.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/util/fipstools/acvp/modulewrapper/main.cc -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/acvp/modulewrapper/main.cc -@@ -37,6 +37,8 @@ int main(int argc, char **argv) { +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/util/fipstools/acvp/modulewrapper/main.cc ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/acvp/modulewrapper/main.cc +@@ -35,6 +35,8 @@ int main(int argc, char **argv) { puts("ARM (32-bit)"); #elif defined(OPENSSL_AARCH64) puts("aarch64 (64-bit)"); @@ -7408,10 +7276,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/acvp/mod #else #error "FIPS build not supported on this architecture" #endif -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/delocate.go +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/delocate.go =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/util/fipstools/delocate/delocate.go -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/delocate.go +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/util/fipstools/delocate/delocate.go ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/delocate.go @@ -54,7 +54,8 @@ type stringWriter interface { type processorType int @@ -7470,7 +7338,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate return statement, nil } -@@ -646,6 +658,191 @@ func (d *delocation) processAarch64Instr +@@ -659,6 +671,191 @@ func (d *delocation) processAarch64Instr return statement, nil } @@ -7570,13 +7438,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate +func (d *delocation) isPPC64LEAPair(statement *node32) (target, source, relative string, ok bool) { + instruction := skipWS(statement.up).up + assertNodeType(instruction, ruleInstructionName) -+ name1 := d.contents(instruction) ++ name1 := d.ccontents(instruction) + args1 := instructionArgs(instruction.next) + + statement = statement.next + instruction = skipWS(statement.up).up + assertNodeType(instruction, ruleInstructionName) -+ name2 := d.contents(instruction) ++ name2 := d.ccontents(instruction) + args2 := instructionArgs(instruction.next) + + if name1 != "addis" || @@ -7586,16 +7454,16 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + return "", "", "", false + } + -+ target = d.contents(args1[0]) -+ relative = d.contents(args1[1]) -+ source1 := d.contents(args1[2]) -+ source2 := d.contents(args2[2]) ++ target = d.ccontents(args1[0]) ++ relative = d.ccontents(args1[1]) ++ source1 := d.ccontents(args1[2]) ++ source2 := d.ccontents(args2[2]) + + if !strings.HasSuffix(source1, "@ha") || + !strings.HasSuffix(source2, "@l") || + source1[:len(source1)-3] != source2[:len(source2)-2] || -+ d.contents(args2[0]) != target || -+ d.contents(args2[1]) != target { ++ d.ccontents(args2[0]) != target || ++ d.ccontents(args2[1]) != target { + return "", "", "", false + } + @@ -7662,13 +7530,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate func (d *delocation) gatherOffsets(symRef *node32, offsets string) (*node32, string) { for symRef != nil && symRef.pegRule == ruleOffset { offset := d.contents(symRef) -@@ -700,6 +897,215 @@ func (d *delocation) parseMemRef(memRef +@@ -713,6 +910,215 @@ func (d *delocation) parseMemRef(memRef return } +func (d *delocation) processPPCInstruction(statement, instruction *node32) (*node32, error) { + assertNodeType(instruction, ruleInstructionName) -+ instructionName := d.contents(instruction) ++ instructionName := d.ccontents(instruction) + isBranch := instructionName[0] == 'b' + + argNodes := instructionArgs(instruction.next) @@ -7689,7 +7557,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + + switch arg.pegRule { + case ruleRegisterOrConstant, ruleLocalLabelRef: -+ args = append(args, d.contents(fullArg)) ++ args = append(args, d.ccontents(fullArg)) + + case ruleTOCRefLow: + return nil, errors.New("Found low TOC reference outside preamble pattern") @@ -7847,7 +7715,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + } + + for ; memRef != nil; memRef = memRef.next { -+ argStr += d.contents(memRef) ++ argStr += d.ccontents(memRef) + } + + args = append(args, argStr) @@ -7878,7 +7746,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate /* Intel */ type instructionType int -@@ -1323,6 +1729,8 @@ func writeAarch64Function(w stringWriter +@@ -1345,6 +1751,8 @@ func writeAarch64Function(w stringWriter func transform(w stringWriter, inputs []inputFile) error { // symbols contains all defined symbols. symbols := make(map[string]struct{}) @@ -7887,13 +7755,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate // fileNumbers is the set of IDs seen in .file directives. fileNumbers := make(map[int]struct{}) // maxObservedFileNumber contains the largest seen file number in a -@@ -1346,6 +1754,25 @@ func transform(w stringWriter, inputs [] +@@ -1368,6 +1776,25 @@ func transform(w stringWriter, inputs [] }, ruleStatement, ruleLabel, ruleSymbolName) forEachPath(input.ast.up, func(node *node32) { + node = node.up + assertNodeType(node, ruleLabelContainingDirectiveName) -+ directive := input.contents[node.begin:node.end] ++ directive := input.ccontents[node.begin:node.end] + if directive != ".localentry" { + return + } @@ -7902,7 +7770,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + assertNodeType(node, ruleSymbolArgs) + node = node.up + assertNodeType(node, ruleSymbolArg) -+ symbol := input.contents[node.begin:node.end] ++ symbol := input.ccontents[node.begin:node.end] + if _, ok := localEntrySymbols[symbol]; ok { + panic(fmt.Sprintf("Duplicate .localentry directive found: %q in %q", symbol, input.path)) + } @@ -7913,7 +7781,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate assertNodeType(node, ruleLocationDirective) directive := input.contents[node.begin:node.end] if !strings.HasPrefix(directive, ".file") { -@@ -1393,11 +1820,13 @@ func transform(w stringWriter, inputs [] +@@ -1415,11 +1842,13 @@ func transform(w stringWriter, inputs [] d := &delocation{ symbols: symbols, @@ -7927,7 +7795,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate gotExternalsNeeded: make(map[string]struct{}), gotOffsetsNeeded: make(map[string]struct{}), gotOffOffsetsNeeded: make(map[string]struct{}), -@@ -1432,6 +1861,22 @@ func transform(w stringWriter, inputs [] +@@ -1454,6 +1883,22 @@ func transform(w stringWriter, inputs [] for _, name := range redirectorNames { redirector := d.redirectors[name] switch d.processor { @@ -7950,7 +7818,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate case aarch64: writeAarch64Function(w, redirector, func(w stringWriter) { w.WriteString("\tb " + name + "\n") -@@ -1456,6 +1901,13 @@ func transform(w stringWriter, inputs [] +@@ -1478,6 +1923,13 @@ func transform(w stringWriter, inputs [] target := d.bssAccessorsNeeded[name] switch d.processor { @@ -7964,7 +7832,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate case x86_64: w.WriteString(".type " + funcName + ", @function\n") w.WriteString(funcName + ":\n") -@@ -1471,6 +1923,26 @@ func transform(w stringWriter, inputs [] +@@ -1493,6 +1945,26 @@ func transform(w stringWriter, inputs [] } switch d.processor { @@ -7991,7 +7859,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate case aarch64: externalNames := sortedSet(d.gotExternalsNeeded) for _, symbol := range externalNames { -@@ -1781,6 +2253,10 @@ func localTargetName(name string) string +@@ -1803,6 +2275,10 @@ func localTargetName(name string) string return ".L" + name + "_local_target" } @@ -8002,7 +7870,7 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate func isSynthesized(symbol string) bool { return strings.HasSuffix(symbol, "_bss_get") || symbol == "OPENSSL_ia32cap_get" || -@@ -1836,6 +2312,8 @@ func detectProcessor(input inputFile) pr +@@ -1894,6 +2370,8 @@ func detectProcessor(input inputFile) pr switch instructionName { case "movq", "call", "leaq": return x86_64 @@ -8011,23 +7879,27 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate case "str", "bl", "ldr", "st1": return aarch64 } -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/delocate.peg +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/delocate.peg =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/util/fipstools/delocate/delocate.peg -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/delocate.peg -@@ -12,7 +12,7 @@ - # OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN - # CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/util/fipstools/delocate/delocate.peg ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/delocate.peg +@@ -12,9 +12,9 @@ + # See the License for the specific language governing permissions and + # limitations under the License. -# This is a rough parser for x86-64 and aarch64 assembly designed to work with -+# This is a rough parser for x86-64 and ppc64le assembly designed to work with - # https://github.com/pointlander/peg. delocate.go has a go:generate line for - # rebuilding delocate.peg.go from this file. +-# https://github.com/pointlander/peg. delocate.go has a go:generate line for +-# rebuilding delocate.peg.go from this file. ++# This is a rough parser for x86-64, ppc64el, and aarch64 assembly designed ++# to work with https://github.com/pointlander/peg. delocate.go has a ++# go:generate line for rebuilding delocate.peg.go from this file. -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/delocate_test.go + # To regenerate delocate.peg.go: + # +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/delocate_test.go =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/util/fipstools/delocate/delocate_test.go -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/delocate_test.go +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/util/fipstools/delocate/delocate_test.go ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/delocate_test.go @@ -39,6 +39,11 @@ func (test *delocateTest) Path(file stri var delocateTests = []delocateTest{ @@ -8040,10 +7912,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate {"x86_64-Basic", []string{"in.s"}, "out.s"}, {"x86_64-BSS", []string{"in.s"}, "out.s"}, {"x86_64-GOTRewrite", []string{"in.s"}, "out.s"}, -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/in.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/in.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/in.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/in.s @@ -0,0 +1,9 @@ + .text +foo: @@ -8054,13 +7926,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + .localentry foo,.-foo +.LVL0: + bl -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/out.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/out.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/out.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-GlobalEntry/out.s @@ -0,0 +1,62 @@ +.text -+.file 1 "inserted_by_delocate.c" ++.file 1 "inserted_by_delocate.cc" +.loc 1 1 0 +BORINGSSL_bcm_text_start: + .text @@ -8121,22 +7993,22 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate +.byte 0xff +.byte 0x31 +.byte 0x80 -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/in.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/in.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/in.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/in.s @@ -0,0 +1,4 @@ + .text +foo: + addis 22,2,bar@toc@ha + ld 0,bar@toc@l(22) -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/out.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/out.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/out.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-LoadToR0/out.s @@ -0,0 +1,72 @@ +.text -+.file 1 "inserted_by_delocate.c" ++.file 1 "inserted_by_delocate.cc" +.loc 1 1 0 +BORINGSSL_bcm_text_start: + .text @@ -8207,12 +8079,12 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate +.byte 0xff +.byte 0x31 +.byte 0x80 -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/in.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/in.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/in.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/in.s @@ -0,0 +1,161 @@ -+ .file "foo.c" ++ .file "foo.cc" + .abiversion 2 + .section ".toc","aw" + .section ".text" @@ -8373,16 +8245,16 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + .size exported_function,.-exported_function + .ident "GCC: (Ubuntu 4.9.2-10ubuntu13) 4.9.2" + .section .note.GNU-stack,"",@progbits -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/out.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/out.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/out.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample/out.s @@ -0,0 +1,552 @@ +.text -+.file 1 "inserted_by_delocate.c" ++.file 1 "inserted_by_delocate.cc" +.loc 1 1 0 +BORINGSSL_bcm_text_start: -+ .file "foo.c" ++ .file "foo.cc" + .abiversion 2 + .section ".toc","aw" +# WAS .section ".text" @@ -8930,12 +8802,12 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate +.byte 0xff +.byte 0x31 +.byte 0x80 -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/in.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/in.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/in.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/in.s @@ -0,0 +1,226 @@ -+ .file "foo.c" ++ .file "foo.cc" + .abiversion 2 + .section ".toc","aw" + .section ".text" @@ -9161,16 +9033,16 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + .zero 20 + .ident "GCC: (Ubuntu 4.9.2-10ubuntu13) 4.9.2" + .section .note.GNU-stack,"",@progbits -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/out.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/out.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/out.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-Sample2/out.s @@ -0,0 +1,677 @@ +.text -+.file 1 "inserted_by_delocate.c" ++.file 1 "inserted_by_delocate.cc" +.loc 1 1 0 +BORINGSSL_bcm_text_start: -+ .file "foo.c" ++ .file "foo.cc" + .abiversion 2 + .section ".toc","aw" +# WAS .section ".text" @@ -9843,10 +9715,10 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate +.byte 0xff +.byte 0x31 +.byte 0x80 -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/in.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/in.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/in.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/in.s @@ -0,0 +1,23 @@ + .text +foo: @@ -9871,13 +9743,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate + + addis 4, 2, 1+foo-2@toc@ha+3 + addi 4, 4, 1+foo-2@toc@l+3 -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/out.s +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/out.s =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/out.s ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/fipstools/delocate/testdata/ppc64le-TOCWithOffset/out.s @@ -0,0 +1,178 @@ +.text -+.file 1 "inserted_by_delocate.c" ++.file 1 "inserted_by_delocate.cc" +.loc 1 1 0 +BORINGSSL_bcm_text_start: + .text @@ -10054,22 +9926,121 @@ Index: chromium-122.0.6261.128/third_party/boringssl/src/util/fipstools/delocate +.byte 0xff +.byte 0x31 +.byte 0x80 -Index: chromium-122.0.6261.128/third_party/boringssl/src/util/generate_build_files.py +Index: chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/sha/sha1.cc.inc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/src/util/generate_build_files.py -+++ chromium-122.0.6261.128/third_party/boringssl/src/util/generate_build_files.py -@@ -35,6 +35,7 @@ OS_ARCH_COMBOS = [ - ('apple', 'x86_64', 'macosx', [], 'S'), - ('linux', 'arm', 'linux32', [], 'S'), - ('linux', 'aarch64', 'linux64', [], 'S'), -+ ('linux', 'ppc64le', 'linux64le', [], 'S'), - ('linux', 'x86', 'elf', ['-fPIC', '-DOPENSSL_IA32_SSE2'], 'S'), - ('linux', 'x86_64', 'elf', [], 'S'), - ('win', 'x86', 'win32n', ['-DOPENSSL_IA32_SSE2'], 'asm'), -Index: chromium-122.0.6261.128/third_party/lss/linux_syscall_support.h +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/crypto/fipsmodule/sha/sha1.cc.inc ++++ chromium-134.0.6998.35/third_party/boringssl/src/crypto/fipsmodule/sha/sha1.cc.inc +@@ -367,6 +367,10 @@ static void sha1_block_data_order(uint32 + return; + } + #endif ++#if defined(SHA1_ASM_PPC64) ++ sha1_block_data_order_ppc64(state, data, num); ++ return; ++#endif + sha1_block_data_order_nohw(state, data, num); + } + +Index: chromium-134.0.6998.35/third_party/boringssl/src/build.json =================================================================== ---- chromium-122.0.6261.128.orig/third_party/lss/linux_syscall_support.h -+++ chromium-122.0.6261.128/third_party/lss/linux_syscall_support.h +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/build.json ++++ chromium-134.0.6998.35/third_party/boringssl/src/build.json +@@ -126,6 +126,10 @@ + {"src": "crypto/fipsmodule/sha/asm/sha512-armv4.pl"}, + {"src": "crypto/fipsmodule/aes/asm/vpaes-armv7.pl"} + ], ++ "perlasm_ppc64le": [ ++ {"src": "crypto/fipsmodule/aes/asm/aesp8-ppc.pl"}, ++ {"src": "crypto/fipsmodule/aes/asm/ghashp8-ppc.pl"} ++ ], + "perlasm_x86": [ + {"src": "crypto/fipsmodule/aes/asm/aesni-x86.pl"}, + {"src": "crypto/fipsmodule/bn/asm/bn-586.pl"}, +@@ -229,6 +233,7 @@ + "crypto/cpu_arm_freebsd.cc", + "crypto/cpu_arm_linux.cc", + "crypto/cpu_intel.cc", ++ "crypto/cpu_ppc64le.cc", + "crypto/crypto.cc", + "crypto/curve25519/curve25519.cc", + "crypto/curve25519/curve25519_64_adx.cc", +@@ -787,6 +792,9 @@ + "perlasm_arm": [ + {"src": "crypto/test/asm/trampoline-armv4.pl"} + ], ++ "perlasm_ppc64le": [ ++ {"src": "crypto/test/asm/trampoline-ppc.pl"} ++ ], + "perlasm_x86": [ + {"src": "crypto/test/asm/trampoline-x86.pl"} + ], +Index: chromium-134.0.6998.35/third_party/boringssl/src/util/pregenerate/build.go +=================================================================== +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/util/pregenerate/build.go ++++ chromium-134.0.6998.35/third_party/boringssl/src/util/pregenerate/build.go +@@ -38,6 +38,7 @@ type InputTarget struct { + // architecture. + PerlasmAarch64 []PerlasmSource `json:"perlasm_aarch64,omitempty"` + PerlasmArm []PerlasmSource `json:"perlasm_arm,omitempty"` ++ PerlasmPPC64LE []PerlasmSource `json:"perlasm_ppc64le,omitempty"` + PerlasmX86 []PerlasmSource `json:"perlasm_x86,omitempty"` + PerlasmX86_64 []PerlasmSource `json:"perlasm_x86_64,omitempty"` + } +@@ -116,6 +117,9 @@ func (in *InputTarget) Pregenerate(name + for _, p := range in.PerlasmArm { + addPerlasmTask(&out.Asm, &p, "-linux.S", []string{"linux32"}) + } ++ for _, p := range in.PerlasmPPC64LE { ++ addPerlasmTask(&out.Asm, &p, "-linux.S", []string{"linux64le"}) ++ } + for _, p := range in.PerlasmX86 { + addPerlasmTask(&out.Asm, &p, "-apple.S", []string{"macosx", "-fPIC"}) + addPerlasmTask(&out.Asm, &p, "-linux.S", []string{"elf", "-fPIC"}) +Index: chromium-134.0.6998.35/third_party/boringssl/README.ppc64le +=================================================================== +--- /dev/null ++++ chromium-134.0.6998.35/third_party/boringssl/README.ppc64le +@@ -0,0 +1,8 @@ ++============================================================== ++To recreate boringssl pregenerated files patch for ppc64le: ++ ++cd third_party/boringssl/src ++cp -Rp gen gen.orig ++go run ./util/pregenerate ++cd ../../../../ ++diff -urN chromium-*/third_party/boringssl/src/gen.orig chromium-*/third_party/boringssl/src/gen +Index: chromium-134.0.6998.35/third_party/boringssl/src/gen/sources.gni +=================================================================== +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/gen/sources.gni ++++ chromium-134.0.6998.35/third_party/boringssl/src/gen/sources.gni +@@ -119,6 +119,7 @@ bcm_sources_asm = [ + "gen/bcm/aesv8-gcm-armv8-apple.S", + "gen/bcm/aesv8-gcm-armv8-linux.S", + "gen/bcm/aesv8-gcm-armv8-win.S", ++ "gen/bcm/aesp8-ppc-linux.S", + "gen/bcm/armv4-mont-linux.S", + "gen/bcm/armv8-mont-apple.S", + "gen/bcm/armv8-mont-linux.S", +@@ -135,6 +136,7 @@ bcm_sources_asm = [ + "gen/bcm/ghash-neon-armv8-apple.S", + "gen/bcm/ghash-neon-armv8-linux.S", + "gen/bcm/ghash-neon-armv8-win.S", ++ "gen/bcm/ghashp8-ppc-linux.S", + "gen/bcm/ghash-ssse3-x86-apple.S", + "gen/bcm/ghash-ssse3-x86-linux.S", + "gen/bcm/ghash-ssse3-x86_64-apple.S", +@@ -328,6 +330,7 @@ crypto_sources = [ + "crypto/cpu_arm_freebsd.cc", + "crypto/cpu_arm_linux.cc", + "crypto/cpu_intel.cc", ++ "crypto/cpu_ppc64le.cc", + "crypto/crypto.cc", + "crypto/curve25519/curve25519.cc", + "crypto/curve25519/curve25519_64_adx.cc", +Index: chromium-134.0.6998.35/third_party/lss/linux_syscall_support.h +=================================================================== +--- chromium-134.0.6998.35.orig/third_party/lss/linux_syscall_support.h ++++ chromium-134.0.6998.35/third_party/lss/linux_syscall_support.h @@ -4638,7 +4638,7 @@ struct kernel_statx { LSS_REG(2, buf); LSS_BODY(void*, mmap2, "0"(__r2)); @@ -10088,10 +10059,10 @@ Index: chromium-122.0.6261.128/third_party/lss/linux_syscall_support.h (defined(__s390__) && !defined(__s390x__)) /* On these architectures, implement mmap() with mmap2(). */ LSS_INLINE void* LSS_NAME(mmap)(void *s, size_t l, int p, int f, int d, -Index: chromium-122.0.6261.128/third_party/lss/linux_syscall_support.h +Index: chromium-134.0.6998.35/third_party/lss/linux_syscall_support.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/lss/linux_syscall_support.h -+++ chromium-122.0.6261.128/third_party/lss/linux_syscall_support.h +--- chromium-134.0.6998.35.orig/third_party/lss/linux_syscall_support.h ++++ chromium-134.0.6998.35/third_party/lss/linux_syscall_support.h @@ -87,7 +87,7 @@ * Porting to other related platforms should not be difficult. */ @@ -10266,11 +10237,11 @@ Subject: [PATCH] Add ppc64 target to libaom third_party/libaom/cmake_update.sh | 3 +++ 2 files changed, 15 insertions(+) -Index: chromium-122.0.6261.128/third_party/libaom/BUILD.gn +Index: chromium-134.0.6998.35/third_party/libaom/BUILD.gn =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libaom/BUILD.gn -+++ chromium-122.0.6261.128/third_party/libaom/BUILD.gn -@@ -268,6 +268,18 @@ if (current_cpu == "arm64") { +--- chromium-134.0.6998.35.orig/third_party/libaom/BUILD.gn ++++ chromium-134.0.6998.35/third_party/libaom/BUILD.gn +@@ -303,6 +303,18 @@ if (current_cpu == "arm64") { } } @@ -10289,7 +10260,7 @@ Index: chromium-122.0.6261.128/third_party/libaom/BUILD.gn static_library("libaom") { check_includes = false if (!is_debug && is_win) { -@@ -333,6 +345,9 @@ static_library("libaom") { +@@ -372,6 +384,9 @@ static_library("libaom") { # This is needed by all arm boards due to aom_arm_cpu_caps() sources += [ "source/libaom/aom_ports/aarch32_cpudetect.c" ] } @@ -10299,27 +10270,27 @@ Index: chromium-122.0.6261.128/third_party/libaom/BUILD.gn if (is_android) { deps += [ "//third_party/cpu_features:ndk_compat" ] } -Index: chromium-122.0.6261.128/third_party/libaom/cmake_update.sh +Index: chromium-134.0.6998.35/third_party/libaom/cmake_update.sh =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libaom/cmake_update.sh -+++ chromium-122.0.6261.128/third_party/libaom/cmake_update.sh -@@ -191,6 +191,9 @@ gen_config_files linux/arm64-cpu-detect - "${toolchain}/arm64-linux-gcc.cmake -DCONFIG_RUNTIME_CPU_DETECT=1 \ - ${all_platforms}" +--- chromium-134.0.6998.35.orig/third_party/libaom/cmake_update.sh ++++ chromium-134.0.6998.35/third_party/libaom/cmake_update.sh +@@ -164,6 +164,9 @@ egrep \ + "#define [A-Z0-9_]+[[:space:]]+[01]" "${CFG}/win/ia32/config/aom_config.h" \ + | awk '{print "%define " $2 " " $3}' > "${CFG}/win/ia32/config/aom_config.asm" +reset_dirs linux/ppc64 +gen_config_files linux/ppc64 "${toolchain}/ppc-linux-gcc.cmake ${all_platforms}" + # Copy linux configurations and modify for Windows. - reset_dirs win/arm64-cpu-detect - cp "${CFG}/linux/arm64-cpu-detect/config"/* \ -Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_config.asm + reset_dirs win/x64 + cp "${CFG}/linux/x64/config"/* "${CFG}/win/x64/config/" +Index: chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_config.asm =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_config.asm -@@ -0,0 +1,92 @@ ++++ chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_config.asm +@@ -0,0 +1,95 @@ +; -+; Copyright (c) 2024, Alliance for Open Media. All rights reserved ++; Copyright (c) 2024, Alliance for Open Media. All rights reserved. +; +; This source code is subject to the terms of the BSD 2 Clause License and +; the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License @@ -10335,7 +10306,7 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +AOM_ARCH_X86_64 equ 0 +CONFIG_ACCOUNTING equ 0 +CONFIG_ANALYZER equ 0 -+CONFIG_AV1_DECODER equ 1 ++CONFIG_AV1_DECODER equ 0 +CONFIG_AV1_ENCODER equ 1 +CONFIG_AV1_HIGHBITDEPTH equ 0 +CONFIG_AV1_TEMPORAL_DENOISING equ 1 @@ -10360,17 +10331,19 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +CONFIG_INSPECTION equ 0 +CONFIG_INTERNAL_STATS equ 0 +CONFIG_INTER_STATS_ONLY equ 0 ++CONFIG_LIBVMAF_PSNR_PEAK equ 1 +CONFIG_LIBYUV equ 0 -+CONFIG_MAX_DECODE_PROFILE equ 0 ++CONFIG_MAX_DECODE_PROFILE equ 2 +CONFIG_MISMATCH_DEBUG equ 0 +CONFIG_MULTITHREAD equ 1 +CONFIG_NN_V2 equ 0 -+CONFIG_NORMAL_TILE_MODE equ 1 ++CONFIG_NORMAL_TILE_MODE equ 0 +CONFIG_OPTICAL_FLOW_API equ 0 +CONFIG_OS_SUPPORT equ 1 +CONFIG_OUTPUT_FRAME_SIZE equ 0 +CONFIG_PARTITION_SEARCH_ORDER equ 0 +CONFIG_PIC equ 1 ++CONFIG_QUANT_MATRIX equ 0 +CONFIG_RATECTRL_LOG equ 0 +CONFIG_RD_COMMAND equ 0 +CONFIG_RD_DEBUG equ 0 @@ -10380,8 +10353,8 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +CONFIG_SALIENCY_MAP equ 0 +CONFIG_SHARED equ 0 +CONFIG_SIZE_LIMIT equ 1 -+CONFIG_SPATIAL_RESAMPLING equ 1 +CONFIG_SPEED_STATS equ 0 ++CONFIG_SVT_AV1 equ 1 +CONFIG_TFLITE equ 0 +CONFIG_THREE_PASS equ 0 +CONFIG_TUNE_BUTTERAUGLI equ 0 @@ -10406,17 +10379,18 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +HAVE_SSE4_2 equ 0 +HAVE_SSSE3 equ 0 +HAVE_SVE equ 0 ++HAVE_SVE2 equ 0 +HAVE_UNISTD_H equ 1 +HAVE_VSX equ 1 +HAVE_WXWIDGETS equ 0 +STATIC_LINK_JXL equ 0 -Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_config.c +Index: chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_config.c =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_config.c ++++ chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_config.c @@ -0,0 +1,13 @@ +/* -+ * Copyright (c) 2024, Alliance for Open Media. All rights reserved ++ * Copyright (c) 2024, Alliance for Open Media. All rights reserved. + * + * This source code is subject to the terms of the BSD 2 Clause License and + * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License @@ -10426,15 +10400,15 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf + * PATENTS file, you can obtain it at www.aomedia.org/license/patent. + */ +#include "aom/aom_codec.h" -+static const char* const cfg = "cmake ../source/libaom -G \"Unix Makefiles\" -DCMAKE_TOOLCHAIN_FILE=\"../source/libaom/build/cmake/toolchains/ppc-linux-gcc.cmake\" -DCONFIG_AV1_ENCODER=1 -DCONFIG_LIBYUV=0 -DCONFIG_AV1_HIGHBITDEPTH=0 -DCONFIG_AV1_TEMPORAL_DENOISING=1 -DCONFIG_REALTIME_ONLY=1 -DCONFIG_MAX_DECODE_PROFILE=0 -DCONFIG_NORMAL_TILE_MODE=1 -DCONFIG_SIZE_LIMIT=1 -DDECODE_HEIGHT_LIMIT=16384 -DDECODE_WIDTH_LIMIT=16384"; ++static const char* const cfg = "cmake ../source/libaom -G \"Unix Makefiles\" -DCMAKE_TOOLCHAIN_FILE=\"../source/libaom/build/cmake/toolchains/ppc-linux-gcc.cmake\" -DCONFIG_AV1_DECODER=0 -DCONFIG_AV1_ENCODER=1 -DCONFIG_LIBYUV=0 -DCONFIG_AV1_HIGHBITDEPTH=0 -DCONFIG_AV1_TEMPORAL_DENOISING=1 -DCONFIG_QUANT_MATRIX=0 -DCONFIG_REALTIME_ONLY=1 -DCONFIG_SIZE_LIMIT=1 -DDECODE_HEIGHT_LIMIT=16384 -DDECODE_WIDTH_LIMIT=16384"; +const char *aom_codec_build_config(void) {return cfg;} -Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_config.h +Index: chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_config.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_config.h -@@ -0,0 +1,96 @@ ++++ chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_config.h +@@ -0,0 +1,98 @@ +/* -+ * Copyright (c) 2024, Alliance for Open Media. All rights reserved ++ * Copyright (c) 2024, Alliance for Open Media. All rights reserved. + * + * This source code is subject to the terms of the BSD 2 Clause License and + * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License @@ -10452,7 +10426,7 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#define AOM_ARCH_X86_64 0 +#define CONFIG_ACCOUNTING 0 +#define CONFIG_ANALYZER 0 -+#define CONFIG_AV1_DECODER 1 ++#define CONFIG_AV1_DECODER 0 +#define CONFIG_AV1_ENCODER 1 +#define CONFIG_AV1_HIGHBITDEPTH 0 +#define CONFIG_AV1_TEMPORAL_DENOISING 1 @@ -10477,17 +10451,19 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#define CONFIG_INSPECTION 0 +#define CONFIG_INTERNAL_STATS 0 +#define CONFIG_INTER_STATS_ONLY 0 ++#define CONFIG_LIBVMAF_PSNR_PEAK 1 +#define CONFIG_LIBYUV 0 -+#define CONFIG_MAX_DECODE_PROFILE 0 ++#define CONFIG_MAX_DECODE_PROFILE 2 +#define CONFIG_MISMATCH_DEBUG 0 +#define CONFIG_MULTITHREAD 1 +#define CONFIG_NN_V2 0 -+#define CONFIG_NORMAL_TILE_MODE 1 ++#define CONFIG_NORMAL_TILE_MODE 0 +#define CONFIG_OPTICAL_FLOW_API 0 +#define CONFIG_OS_SUPPORT 1 +#define CONFIG_OUTPUT_FRAME_SIZE 0 +#define CONFIG_PARTITION_SEARCH_ORDER 0 +#define CONFIG_PIC 1 ++#define CONFIG_QUANT_MATRIX 0 +#define CONFIG_RATECTRL_LOG 0 +#define CONFIG_RD_COMMAND 0 +#define CONFIG_RD_DEBUG 0 @@ -10497,8 +10473,8 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#define CONFIG_SALIENCY_MAP 0 +#define CONFIG_SHARED 0 +#define CONFIG_SIZE_LIMIT 1 -+#define CONFIG_SPATIAL_RESAMPLING 1 +#define CONFIG_SPEED_STATS 0 ++#define CONFIG_SVT_AV1 1 +#define CONFIG_TFLITE 0 +#define CONFIG_THREE_PASS 0 +#define CONFIG_TUNE_BUTTERAUGLI 0 @@ -10523,17 +10499,28 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#define HAVE_SSE4_2 0 +#define HAVE_SSSE3 0 +#define HAVE_SVE 0 ++#define HAVE_SVE2 0 +#define HAVE_UNISTD_H 1 +#define HAVE_VSX 1 +#define HAVE_WXWIDGETS 0 -+#define INLINE inline +#define STATIC_LINK_JXL 0 +#endif // AOM_CONFIG_H_ -Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_dsp_rtcd.h +Index: chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_dsp_rtcd.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_dsp_rtcd.h -@@ -0,0 +1,1541 @@ ++++ chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_dsp_rtcd.h +@@ -0,0 +1,1501 @@ ++/* ++ * Copyright (c) 2024, Alliance for Open Media. All rights reserved. ++ * ++ * This source code is subject to the terms of the BSD 2 Clause License and ++ * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License ++ * was not distributed with this source code in the LICENSE file, you can ++ * obtain it at www.aomedia.org/license/software. If the Alliance for Open ++ * Media Patent License 1.0 was not distributed with this source code in the ++ * PATENTS file, you can obtain it at www.aomedia.org/license/patent. ++ */ ++ +// This file is generated. Do not edit. +#ifndef AOM_DSP_RTCD_H_ +#define AOM_DSP_RTCD_H_ @@ -10582,9 +10569,6 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +void aom_comp_mask_pred_c(uint8_t *comp_pred, const uint8_t *pred, int width, int height, const uint8_t *ref, int ref_stride, const uint8_t *mask, int mask_stride, int invert_mask); +#define aom_comp_mask_pred aom_comp_mask_pred_c + -+void aom_convolve8_c(const uint8_t *src, ptrdiff_t src_stride, uint8_t *dst, ptrdiff_t dst_stride, const InterpKernel *filter, int x0_q4, int x_step_q4, int y0_q4, int y_step_q4, int w, int h); -+#define aom_convolve8 aom_convolve8_c -+ +void aom_convolve8_horiz_c(const uint8_t *src, ptrdiff_t src_stride, uint8_t *dst, ptrdiff_t dst_stride, const int16_t *filter_x, int x_step_q4, const int16_t *filter_y, int y_step_q4, int w, int h); +#define aom_convolve8_horiz aom_convolve8_horiz_c + @@ -11131,99 +11115,51 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +unsigned int aom_masked_sad128x128_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad128x128 aom_masked_sad128x128_c + -+void aom_masked_sad128x128x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad128x128x4d aom_masked_sad128x128x4d_c -+ +unsigned int aom_masked_sad128x64_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad128x64 aom_masked_sad128x64_c + -+void aom_masked_sad128x64x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad128x64x4d aom_masked_sad128x64x4d_c -+ +unsigned int aom_masked_sad16x16_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad16x16 aom_masked_sad16x16_c + -+void aom_masked_sad16x16x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad16x16x4d aom_masked_sad16x16x4d_c -+ +unsigned int aom_masked_sad16x32_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad16x32 aom_masked_sad16x32_c + -+void aom_masked_sad16x32x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad16x32x4d aom_masked_sad16x32x4d_c -+ +unsigned int aom_masked_sad16x8_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad16x8 aom_masked_sad16x8_c + -+void aom_masked_sad16x8x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad16x8x4d aom_masked_sad16x8x4d_c -+ +unsigned int aom_masked_sad32x16_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad32x16 aom_masked_sad32x16_c + -+void aom_masked_sad32x16x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad32x16x4d aom_masked_sad32x16x4d_c -+ +unsigned int aom_masked_sad32x32_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad32x32 aom_masked_sad32x32_c + -+void aom_masked_sad32x32x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad32x32x4d aom_masked_sad32x32x4d_c -+ +unsigned int aom_masked_sad32x64_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad32x64 aom_masked_sad32x64_c + -+void aom_masked_sad32x64x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad32x64x4d aom_masked_sad32x64x4d_c -+ +unsigned int aom_masked_sad4x4_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad4x4 aom_masked_sad4x4_c + -+void aom_masked_sad4x4x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad4x4x4d aom_masked_sad4x4x4d_c -+ +unsigned int aom_masked_sad4x8_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad4x8 aom_masked_sad4x8_c + -+void aom_masked_sad4x8x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad4x8x4d aom_masked_sad4x8x4d_c -+ +unsigned int aom_masked_sad64x128_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad64x128 aom_masked_sad64x128_c + -+void aom_masked_sad64x128x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad64x128x4d aom_masked_sad64x128x4d_c -+ +unsigned int aom_masked_sad64x32_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad64x32 aom_masked_sad64x32_c + -+void aom_masked_sad64x32x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad64x32x4d aom_masked_sad64x32x4d_c -+ +unsigned int aom_masked_sad64x64_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad64x64 aom_masked_sad64x64_c + -+void aom_masked_sad64x64x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad64x64x4d aom_masked_sad64x64x4d_c -+ +unsigned int aom_masked_sad8x16_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad8x16 aom_masked_sad8x16_c + -+void aom_masked_sad8x16x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad8x16x4d aom_masked_sad8x16x4d_c -+ +unsigned int aom_masked_sad8x4_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad8x4 aom_masked_sad8x4_c + -+void aom_masked_sad8x4x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad8x4x4d aom_masked_sad8x4x4d_c -+ +unsigned int aom_masked_sad8x8_c(const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask); +#define aom_masked_sad8x8 aom_masked_sad8x8_c + -+void aom_masked_sad8x8x4d_c(const uint8_t *src, int src_stride, const uint8_t *ref[4], int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned sads[4]); -+#define aom_masked_sad8x8x4d aom_masked_sad8x8x4d_c -+ +unsigned int aom_masked_sub_pixel_variance128x128_c(const uint8_t *src, int src_stride, int xoffset, int yoffset, const uint8_t *ref, int ref_stride, const uint8_t *second_pred, const uint8_t *msk, int msk_stride, int invert_mask, unsigned int *sse); +#define aom_masked_sub_pixel_variance128x128 aom_masked_sub_pixel_variance128x128_c + @@ -12075,11 +12011,22 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#endif + +#endif -Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_scale_rtcd.h +Index: chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_scale_rtcd.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/aom_scale_rtcd.h -@@ -0,0 +1,105 @@ ++++ chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/aom_scale_rtcd.h +@@ -0,0 +1,91 @@ ++/* ++ * Copyright (c) 2024, Alliance for Open Media. All rights reserved. ++ * ++ * This source code is subject to the terms of the BSD 2 Clause License and ++ * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License ++ * was not distributed with this source code in the LICENSE file, you can ++ * obtain it at www.aomedia.org/license/software. If the Alliance for Open ++ * Media Patent License 1.0 was not distributed with this source code in the ++ * PATENTS file, you can obtain it at www.aomedia.org/license/patent. ++ */ ++ +// This file is generated. Do not edit. +#ifndef AOM_SCALE_RTCD_H_ +#define AOM_SCALE_RTCD_H_ @@ -12090,55 +12037,30 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#define RTCD_EXTERN extern +#endif + ++#include ++ +struct yv12_buffer_config; + +#ifdef __cplusplus +extern "C" { +#endif + -+void aom_extend_frame_borders_c(struct yv12_buffer_config *ybf, const int num_planes); ++void aom_extend_frame_borders_c(struct yv12_buffer_config *ybf, int num_planes); +#define aom_extend_frame_borders aom_extend_frame_borders_c + +void aom_extend_frame_borders_plane_row_c(const struct yv12_buffer_config *ybf, int plane, int v_start, int v_end); +#define aom_extend_frame_borders_plane_row aom_extend_frame_borders_plane_row_c + -+void aom_extend_frame_borders_y_c(struct yv12_buffer_config *ybf); -+#define aom_extend_frame_borders_y aom_extend_frame_borders_y_c -+ -+void aom_extend_frame_inner_borders_c(struct yv12_buffer_config *ybf, const int num_planes); -+#define aom_extend_frame_inner_borders aom_extend_frame_inner_borders_c -+ -+void aom_horizontal_line_2_1_scale_c(const unsigned char *source, unsigned int source_width, unsigned char *dest, unsigned int dest_width); -+#define aom_horizontal_line_2_1_scale aom_horizontal_line_2_1_scale_c -+ -+void aom_horizontal_line_5_3_scale_c(const unsigned char *source, unsigned int source_width, unsigned char *dest, unsigned int dest_width); -+#define aom_horizontal_line_5_3_scale aom_horizontal_line_5_3_scale_c -+ -+void aom_horizontal_line_5_4_scale_c(const unsigned char *source, unsigned int source_width, unsigned char *dest, unsigned int dest_width); -+#define aom_horizontal_line_5_4_scale aom_horizontal_line_5_4_scale_c -+ -+void aom_vertical_band_2_1_scale_c(unsigned char *source, int src_pitch, unsigned char *dest, int dest_pitch, unsigned int dest_width); -+#define aom_vertical_band_2_1_scale aom_vertical_band_2_1_scale_c -+ -+void aom_vertical_band_2_1_scale_i_c(unsigned char *source, int src_pitch, unsigned char *dest, int dest_pitch, unsigned int dest_width); -+#define aom_vertical_band_2_1_scale_i aom_vertical_band_2_1_scale_i_c -+ -+void aom_vertical_band_5_3_scale_c(unsigned char *source, int src_pitch, unsigned char *dest, int dest_pitch, unsigned int dest_width); -+#define aom_vertical_band_5_3_scale aom_vertical_band_5_3_scale_c -+ -+void aom_vertical_band_5_4_scale_c(unsigned char *source, int src_pitch, unsigned char *dest, int dest_pitch, unsigned int dest_width); -+#define aom_vertical_band_5_4_scale aom_vertical_band_5_4_scale_c -+ +void aom_yv12_copy_frame_c(const struct yv12_buffer_config *src_bc, struct yv12_buffer_config *dst_bc, const int num_planes); +#define aom_yv12_copy_frame aom_yv12_copy_frame_c + -+void aom_yv12_copy_u_c(const struct yv12_buffer_config *src_bc, struct yv12_buffer_config *dst_bc); ++void aom_yv12_copy_u_c(const struct yv12_buffer_config *src_bc, struct yv12_buffer_config *dst_bc, int use_crop); +#define aom_yv12_copy_u aom_yv12_copy_u_c + -+void aom_yv12_copy_v_c(const struct yv12_buffer_config *src_bc, struct yv12_buffer_config *dst_bc); ++void aom_yv12_copy_v_c(const struct yv12_buffer_config *src_bc, struct yv12_buffer_config *dst_bc, int use_crop); +#define aom_yv12_copy_v aom_yv12_copy_v_c + -+void aom_yv12_copy_y_c(const struct yv12_buffer_config *src_ybc, struct yv12_buffer_config *dst_ybc); ++void aom_yv12_copy_y_c(const struct yv12_buffer_config *src_ybc, struct yv12_buffer_config *dst_ybc, int use_crop); +#define aom_yv12_copy_y aom_yv12_copy_y_c + +void aom_yv12_extend_frame_borders_c(struct yv12_buffer_config *ybf, const int num_planes); @@ -12162,7 +12084,7 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +void aom_yv12_partial_copy_y_c(const struct yv12_buffer_config *src_ybc, int hstart1, int hend1, int vstart1, int vend1, struct yv12_buffer_config *dst_ybc, int hstart2, int vstart2); +#define aom_yv12_partial_copy_y aom_yv12_partial_copy_y_c + -+int aom_yv12_realloc_with_new_border_c(struct yv12_buffer_config *ybf, int new_border, int byte_alignment, int num_pyramid_levels, int num_planes); ++int aom_yv12_realloc_with_new_border_c(struct yv12_buffer_config *ybf, int new_border, int byte_alignment, bool alloc_pyramid, int num_planes); +#define aom_yv12_realloc_with_new_border aom_yv12_realloc_with_new_border_c + +void aom_scale_rtcd(void); @@ -12185,11 +12107,22 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#endif + +#endif -Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/av1_rtcd.h +Index: chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/av1_rtcd.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/config/av1_rtcd.h -@@ -0,0 +1,478 @@ ++++ chromium-134.0.6998.35/third_party/libaom/source/config/linux/ppc64/config/av1_rtcd.h +@@ -0,0 +1,438 @@ ++/* ++ * Copyright (c) 2024, Alliance for Open Media. All rights reserved. ++ * ++ * This source code is subject to the terms of the BSD 2 Clause License and ++ * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License ++ * was not distributed with this source code in the LICENSE file, you can ++ * obtain it at www.aomedia.org/license/software. If the Alliance for Open ++ * Media Patent License 1.0 was not distributed with this source code in the ++ * PATENTS file, you can obtain it at www.aomedia.org/license/patent. ++ */ ++ +// This file is generated. Do not edit. +#ifndef AV1_RTCD_H_ +#define AV1_RTCD_H_ @@ -12274,12 +12207,6 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf + int ref_stride, int subpel_search); +#define aom_comp_avg_upsampled_pred aom_comp_avg_upsampled_pred_c + -+void aom_dist_wtd_comp_avg_upsampled_pred_c(MACROBLOCKD *xd, const struct AV1Common *const cm, int mi_row, int mi_col, -+ const MV *const mv, uint8_t *comp_pred, const uint8_t *pred, int width, -+ int height, int subpel_x_q3, int subpel_y_q3, const uint8_t *ref, -+ int ref_stride, const DIST_WTD_COMP_PARAMS *jcp_param, int subpel_search); -+#define aom_dist_wtd_comp_avg_upsampled_pred aom_dist_wtd_comp_avg_upsampled_pred_c -+ +void aom_quantize_b_helper_c(const tran_low_t *coeff_ptr, intptr_t n_coeffs, const int16_t *zbin_ptr, const int16_t *round_ptr, const int16_t *quant_ptr, const int16_t *quant_shift_ptr, tran_low_t *qcoeff_ptr, tran_low_t *dqcoeff_ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, const int16_t *iscan, const qm_val_t *qm_ptr, const qm_val_t *iqm_ptr, const int log_scale); +#define aom_quantize_b_helper aom_quantize_b_helper_c + @@ -12357,6 +12284,9 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +void av1_dr_prediction_z3_c(uint8_t *dst, ptrdiff_t stride, int bw, int bh, const uint8_t *above, const uint8_t *left, int upsample_left, int dx, int dy); +#define av1_dr_prediction_z3 av1_dr_prediction_z3_c + ++void av1_fdwt8x8_uint8_input_c(const uint8_t *input, tran_low_t *output, int stride, int hbd); ++#define av1_fdwt8x8_uint8_input av1_fdwt8x8_uint8_input_c ++ +void av1_filter_intra_edge_c(uint8_t *p, int sz, int strength); +#define av1_filter_intra_edge av1_filter_intra_edge_c + @@ -12420,60 +12350,6 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +void av1_highbd_inv_txfm_add_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); +#define av1_highbd_inv_txfm_add av1_highbd_inv_txfm_add_c + -+void av1_highbd_inv_txfm_add_16x32_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_16x32 av1_highbd_inv_txfm_add_16x32_c -+ -+void av1_highbd_inv_txfm_add_16x4_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_16x4 av1_highbd_inv_txfm_add_16x4_c -+ -+void av1_highbd_inv_txfm_add_16x64_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_16x64 av1_highbd_inv_txfm_add_16x64_c -+ -+void av1_highbd_inv_txfm_add_16x8_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_16x8 av1_highbd_inv_txfm_add_16x8_c -+ -+void av1_highbd_inv_txfm_add_32x16_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_32x16 av1_highbd_inv_txfm_add_32x16_c -+ -+void av1_highbd_inv_txfm_add_32x32_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_32x32 av1_highbd_inv_txfm_add_32x32_c -+ -+void av1_highbd_inv_txfm_add_32x64_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_32x64 av1_highbd_inv_txfm_add_32x64_c -+ -+void av1_highbd_inv_txfm_add_32x8_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_32x8 av1_highbd_inv_txfm_add_32x8_c -+ -+void av1_highbd_inv_txfm_add_4x16_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_4x16 av1_highbd_inv_txfm_add_4x16_c -+ -+void av1_highbd_inv_txfm_add_4x4_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_4x4 av1_highbd_inv_txfm_add_4x4_c -+ -+void av1_highbd_inv_txfm_add_4x8_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_4x8 av1_highbd_inv_txfm_add_4x8_c -+ -+void av1_highbd_inv_txfm_add_64x16_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_64x16 av1_highbd_inv_txfm_add_64x16_c -+ -+void av1_highbd_inv_txfm_add_64x32_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_64x32 av1_highbd_inv_txfm_add_64x32_c -+ -+void av1_highbd_inv_txfm_add_64x64_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_64x64 av1_highbd_inv_txfm_add_64x64_c -+ -+void av1_highbd_inv_txfm_add_8x16_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_8x16 av1_highbd_inv_txfm_add_8x16_c -+ -+void av1_highbd_inv_txfm_add_8x32_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_8x32 av1_highbd_inv_txfm_add_8x32_c -+ -+void av1_highbd_inv_txfm_add_8x4_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_8x4 av1_highbd_inv_txfm_add_8x4_c -+ -+void av1_highbd_inv_txfm_add_8x8_c(const tran_low_t *input, uint8_t *dest, int stride, const TxfmParam *txfm_param); -+#define av1_highbd_inv_txfm_add_8x8 av1_highbd_inv_txfm_add_8x8_c -+ +void av1_highbd_iwht4x4_16_add_c(const tran_low_t *input, uint8_t *dest, int dest_stride, int bd); +#define av1_highbd_iwht4x4_16_add av1_highbd_iwht4x4_16_add_c + @@ -12567,6 +12443,12 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +void av1_resize_and_extend_frame_c(const YV12_BUFFER_CONFIG *src, YV12_BUFFER_CONFIG *dst, const InterpFilter filter, const int phase, const int num_planes); +#define av1_resize_and_extend_frame av1_resize_and_extend_frame_c + ++void av1_resize_horz_dir_c(const uint8_t *const input, int in_stride, uint8_t *intbuf, int height, int filtered_length, int width2); ++#define av1_resize_horz_dir av1_resize_horz_dir_c ++ ++bool av1_resize_vert_dir_c(uint8_t *intbuf, uint8_t *output, int out_stride, int height, int height2, int width2, int start_col); ++#define av1_resize_vert_dir av1_resize_vert_dir_c ++ +void av1_round_shift_array_c(int32_t *arr, int size, int bit); +#define av1_round_shift_array av1_round_shift_array_c + @@ -12668,11 +12550,21 @@ Index: chromium-122.0.6261.128/third_party/libaom/source/config/linux/ppc64/conf +#endif + +#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h +--- chromium-134.0.6998.35.orig/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h +++ /dev/null -@@ -1,320 +0,0 @@ +@@ -1,330 +0,0 @@ +-/* +- * Copyright (c) 2025 The WebM project authors. All Rights Reserved. +- * +- * Use of this source code is governed by a BSD-style license +- * that can be found in the LICENSE file in the root of the source +- * tree. An additional intellectual property rights grant can be found +- * in the file PATENTS. All contributing project authors may +- * be found in the AUTHORS file in the root of the source tree. +- */ +- -// This file is generated. Do not edit. -#ifndef VP8_RTCD_H_ -#define VP8_RTCD_H_ @@ -12992,12 +12884,22 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp8_ -} // extern "C" -#endif - --#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h +-#endif // VP8_RTCD_H_ +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h +--- chromium-134.0.6998.35.orig/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h +++ /dev/null -@@ -1,193 +0,0 @@ +@@ -1,206 +0,0 @@ +-/* +- * Copyright (c) 2025 The WebM project authors. All Rights Reserved. +- * +- * Use of this source code is governed by a BSD-style license +- * that can be found in the LICENSE file in the root of the source +- * tree. An additional intellectual property rights grant can be found +- * in the file PATENTS. All contributing project authors may +- * be found in the AUTHORS file in the root of the source tree. +- */ +- -// This file is generated. Do not edit. -#ifndef VP9_RTCD_H_ -#define VP9_RTCD_H_ @@ -13016,6 +12918,9 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp9_ -#include "vp9/common/vp9_enums.h" -#include "vp9/common/vp9_filter.h" -#include "vpx/vpx_integer.h" +-#if !CONFIG_REALTIME_ONLY && CONFIG_VP9_ENCODER +-#include "vp9/encoder/vp9_temporal_filter.h" +-#endif - -struct macroblockd; - @@ -13190,12 +13095,12 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp9_ -} // extern "C" -#endif - --#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm +-#endif // VP9_RTCD_H_ +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm +--- chromium-134.0.6998.35.orig/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm +++ /dev/null -@@ -1,107 +0,0 @@ +@@ -1,108 +0,0 @@ -@ This file was created from a .asm file -@ using the ads2gas.pl script. -.syntax unified @@ -13218,6 +13123,7 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ -.equ HAVE_NEON_DOTPROD , 0 -.equ HAVE_NEON_I8MM , 0 -.equ HAVE_SVE , 0 +-.equ HAVE_SVE2 , 0 -.equ HAVE_MIPS32 , 0 -.equ HAVE_DSPR2 , 0 -.equ HAVE_MSA , 0 @@ -13303,9 +13209,9 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ -.equ DECODE_WIDTH_LIMIT , 16384 -.equ DECODE_HEIGHT_LIMIT , 16384 - .section .note.GNU-stack,"",%progbits -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.c +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.c =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libvpx/source/config/linux/ppc64/vpx_config.c +--- chromium-134.0.6998.35.orig/third_party/libvpx/source/config/linux/ppc64/vpx_config.c +++ /dev/null @@ -1,10 +0,0 @@ -/* Copyright (c) 2011 The WebM project authors. All Rights Reserved. */ @@ -13316,13 +13222,13 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ -/* in the file PATENTS. All contributing project authors may */ -/* be found in the AUTHORS file in the root of the source tree. */ -#include "vpx/vpx_codec.h" --static const char* const cfg = "--target=ppc64le-linux-gcc --enable-external-build --enable-postproc --enable-multi-res-encoding --enable-temporal-denoising --enable-vp9-temporal-denoising --enable-vp9-postproc --size-limit=16384x16384 --enable-realtime-only --disable-install-docs --disable-libyuv"; +-static const char* const cfg = "--target=ppc64le-linux-gcc --enable-external-build --enable-postproc --enable-multi-res-encoding --enable-temporal-denoising --enable-vp9-temporal-denoising --enable-vp9-postproc --size-limit=16384x16384 --enable-realtime-only --disable-install-docs --disable-libyuv --enable-unit-tests"; -const char *vpx_codec_build_config(void) {return cfg;} -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libvpx/source/config/linux/ppc64/vpx_config.h +--- chromium-134.0.6998.35.orig/third_party/libvpx/source/config/linux/ppc64/vpx_config.h +++ /dev/null -@@ -1,116 +0,0 @@ +@@ -1,117 +0,0 @@ -/* Copyright (c) 2011 The WebM project authors. All Rights Reserved. */ -/* */ -/* Use of this source code is governed by a BSD-style license */ @@ -13354,6 +13260,7 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ -#define HAVE_NEON_DOTPROD 0 -#define HAVE_NEON_I8MM 0 -#define HAVE_SVE 0 +-#define HAVE_SVE2 0 -#define HAVE_MIPS32 0 -#define HAVE_DSPR2 0 -#define HAVE_MSA 0 @@ -13439,11 +13346,21 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ -#define DECODE_WIDTH_LIMIT 16384 -#define DECODE_HEIGHT_LIMIT 16384 -#endif /* VPX_CONFIG_H */ -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h +--- chromium-134.0.6998.35.orig/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h +++ /dev/null -@@ -1,2128 +0,0 @@ +@@ -1,2138 +0,0 @@ +-/* +- * Copyright (c) 2025 The WebM project authors. All Rights Reserved. +- * +- * Use of this source code is governed by a BSD-style license +- * that can be found in the LICENSE file in the root of the source +- * tree. An additional intellectual property rights grant can be found +- * in the file PATENTS. All contributing project authors may +- * be found in the AUTHORS file in the root of the source tree. +- */ +- -// This file is generated. Do not edit. -#ifndef VPX_DSP_RTCD_H_ -#define VPX_DSP_RTCD_H_ @@ -15571,12 +15488,22 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ -} // extern "C" -#endif - --#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h +-#endif // VPX_DSP_RTCD_H_ +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h +--- chromium-134.0.6998.35.orig/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h +++ /dev/null -@@ -1,100 +0,0 @@ +@@ -1,110 +0,0 @@ +-/* +- * Copyright (c) 2025 The WebM project authors. All Rights Reserved. +- * +- * Use of this source code is governed by a BSD-style license +- * that can be found in the LICENSE file in the root of the source +- * tree. An additional intellectual property rights grant can be found +- * in the file PATENTS. All contributing project authors may +- * be found in the AUTHORS file in the root of the source tree. +- */ +- -// This file is generated. Do not edit. -#ifndef VPX_SCALE_RTCD_H_ -#define VPX_SCALE_RTCD_H_ @@ -15676,33 +15603,11 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ -} // extern "C" -#endif - --#endif -Index: chromium-122.0.6261.128/third_party/boringssl/BUILD.generated.gni -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/boringssl/BUILD.generated.gni -+++ chromium-122.0.6261.128/third_party/boringssl/BUILD.generated.gni -@@ -94,6 +94,7 @@ crypto_sources = [ - "src/crypto/cpu_arm_linux.c", - "src/crypto/cpu_arm_linux.h", - "src/crypto/cpu_intel.c", -+ "src/crypto/cpu_ppc64le.c", - "src/crypto/crypto.c", - "src/crypto/curve25519/curve25519.c", - "src/crypto/curve25519/curve25519_64_adx.c", -@@ -401,6 +402,9 @@ crypto_sources_asm = [ - "linux-arm/crypto/fipsmodule/sha512-armv4-linux.S", - "linux-arm/crypto/fipsmodule/vpaes-armv7-linux.S", - "linux-arm/crypto/test/trampoline-armv4-linux.S", -+ "linux-ppc64le/crypto/fipsmodule/aesp8-ppc-linux.S", -+ "linux-ppc64le/crypto/fipsmodule/ghashp8-ppc-linux.S", -+ "linux-ppc64le/crypto/test/trampoline-ppc-linux.S", - "linux-x86/crypto/chacha/chacha-x86-linux.S", - "linux-x86/crypto/fipsmodule/aesni-x86-linux.S", - "linux-x86/crypto/fipsmodule/bn-586-linux.S", -Index: chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/fipsmodule/aesp8-ppc-linux.S +-#endif // VPX_SCALE_RTCD_H_ +Index: chromium-134.0.6998.35/third_party/boringssl/src/gen/bcm/aesp8-ppc-linux.S =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/fipsmodule/aesp8-ppc-linux.S ++++ chromium-134.0.6998.35/third_party/boringssl/src/gen/bcm/aesp8-ppc-linux.S @@ -0,0 +1,3673 @@ +// This file is generated from a similarly-named Perl script in the BoringSSL +// source tree. Do not edit by hand. @@ -19374,13 +19279,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/fipsmo +.byte 0,12,0x14,0,0,0,0,0 +#endif // !OPENSSL_NO_ASM && __powerpc64__ && __ELF__ +#if defined(__ELF__) -+// See https://www.airs.com/blog/archives/518. ++// See https://www.airs.ccom/blog/archives/518. +.section .note.GNU-stack,"",%progbits +#endif -Index: chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/fipsmodule/ghashp8-ppc-linux.S +Index: chromium-134.0.6998.35/third_party/boringssl/src/gen/bcm/ghashp8-ppc-linux.S =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/fipsmodule/ghashp8-ppc-linux.S ++++ chromium-134.0.6998.35/third_party/boringssl/src/gen/bcm/ghashp8-ppc-linux.S @@ -0,0 +1,590 @@ +// This file is generated from a similarly-named Perl script in the BoringSSL +// source tree. Do not edit by hand. @@ -19969,13 +19874,85 @@ Index: chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/fipsmo +.align 2 +#endif // !OPENSSL_NO_ASM && __powerpc64__ && __ELF__ +#if defined(__ELF__) -+// See https://www.airs.com/blog/archives/518. ++// See https://www.airs.ccom/blog/archives/518. +.section .note.GNU-stack,"",%progbits +#endif -Index: chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/test/trampoline-ppc-linux.S +Index: chromium-134.0.6998.35/third_party/boringssl/src/gen/sources.cmake +=================================================================== +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/gen/sources.cmake ++++ chromium-134.0.6998.35/third_party/boringssl/src/gen/sources.cmake +@@ -118,6 +118,7 @@ set( + gen/bcm/aesni-x86-linux.S + gen/bcm/aesni-x86_64-apple.S + gen/bcm/aesni-x86_64-linux.S ++ gen/bcm/aesp8-ppc-linux.S + gen/bcm/aesv8-armv7-linux.S + gen/bcm/aesv8-armv8-apple.S + gen/bcm/aesv8-armv8-linux.S +@@ -149,6 +150,7 @@ set( + gen/bcm/ghash-x86-linux.S + gen/bcm/ghash-x86_64-apple.S + gen/bcm/ghash-x86_64-linux.S ++ gen/bcm/ghashp8-ppc-linux.S + gen/bcm/ghashv8-armv7-linux.S + gen/bcm/ghashv8-armv8-apple.S + gen/bcm/ghashv8-armv8-linux.S +@@ -342,6 +344,7 @@ set( + crypto/cpu_arm_freebsd.cc + crypto/cpu_arm_linux.cc + crypto/cpu_intel.cc ++ crypto/cpu_ppc64le.cc + crypto/crypto.cc + crypto/curve25519/curve25519.cc + crypto/curve25519/curve25519_64_adx.cc +@@ -2832,6 +2835,7 @@ set( + gen/test_support/trampoline-armv8-apple.S + gen/test_support/trampoline-armv8-linux.S + gen/test_support/trampoline-armv8-win.S ++ gen/test_support/trampoline-ppc-linux.S + gen/test_support/trampoline-x86-apple.S + gen/test_support/trampoline-x86-linux.S + gen/test_support/trampoline-x86_64-apple.S +Index: chromium-134.0.6998.35/third_party/boringssl/src/gen/sources.json +=================================================================== +--- chromium-134.0.6998.35.orig/third_party/boringssl/src/gen/sources.json ++++ chromium-134.0.6998.35/third_party/boringssl/src/gen/sources.json +@@ -96,6 +96,7 @@ + "gen/bcm/aesni-x86-linux.S", + "gen/bcm/aesni-x86_64-apple.S", + "gen/bcm/aesni-x86_64-linux.S", ++ "gen/bcm/aesp8-ppc-linux.S", + "gen/bcm/aesv8-armv7-linux.S", + "gen/bcm/aesv8-armv8-apple.S", + "gen/bcm/aesv8-armv8-linux.S", +@@ -127,6 +128,7 @@ + "gen/bcm/ghash-x86-linux.S", + "gen/bcm/ghash-x86_64-apple.S", + "gen/bcm/ghash-x86_64-linux.S", ++ "gen/bcm/ghashp8-ppc-linux.S", + "gen/bcm/ghashv8-armv7-linux.S", + "gen/bcm/ghashv8-armv8-apple.S", + "gen/bcm/ghashv8-armv8-linux.S", +@@ -312,6 +314,7 @@ + "crypto/cpu_arm_freebsd.cc", + "crypto/cpu_arm_linux.cc", + "crypto/cpu_intel.cc", ++ "crypto/cpu_ppc64le.cc", + "crypto/crypto.cc", + "crypto/curve25519/curve25519.cc", + "crypto/curve25519/curve25519_64_adx.cc", +@@ -2752,6 +2755,7 @@ + "gen/test_support/trampoline-armv8-apple.S", + "gen/test_support/trampoline-armv8-linux.S", + "gen/test_support/trampoline-armv8-win.S", ++ "gen/test_support/trampoline-ppc-linux.S", + "gen/test_support/trampoline-x86-apple.S", + "gen/test_support/trampoline-x86-linux.S", + "gen/test_support/trampoline-x86_64-apple.S", +Index: chromium-134.0.6998.35/third_party/boringssl/src/gen/test_support/trampoline-ppc-linux.S =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/test/trampoline-ppc-linux.S ++++ chromium-134.0.6998.35/third_party/boringssl/src/gen/test_support/trampoline-ppc-linux.S @@ -0,0 +1,1413 @@ +// This file is generated from a similarly-named Perl script in the BoringSSL +// source tree. Do not edit by hand. @@ -21387,13 +21364,13 @@ Index: chromium-122.0.6261.128/third_party/boringssl/linux-ppc64le/crypto/test/t + +#endif // !OPENSSL_NO_ASM && __powerpc64__ && __ELF__ +#if defined(__ELF__) -+// See https://www.airs.com/blog/archives/518. ++// See https://www.airs.ccom/blog/archives/518. +.section .note.GNU-stack,"",%progbits +#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h ++++ chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vp8_rtcd.h @@ -0,0 +1,316 @@ +// This file is generated. Do not edit. +#ifndef VP8_RTCD_H_ @@ -21711,10 +21688,10 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp8_ +#endif + +#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h ++++ chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vp9_rtcd.h @@ -0,0 +1,267 @@ +// This file is generated. Do not edit. +#ifndef VP9_RTCD_H_ @@ -21983,10 +21960,10 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vp9_ +#endif + +#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm ++++ chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.asm @@ -0,0 +1,107 @@ +@ This file was created from a .asm file +@ using the ads2gas.pl script. @@ -22095,10 +22072,10 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ +.equ DECODE_WIDTH_LIMIT , 16384 +.equ DECODE_HEIGHT_LIMIT , 16384 + .section .note.GNU-stack,"",%progbits -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.c +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.c =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.c ++++ chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.c @@ -0,0 +1,10 @@ +/* Copyright (c) 2011 The WebM project authors. All Rights Reserved. */ +/* */ @@ -22110,10 +22087,10 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ +#include "vpx/vpx_codec.h" +static const char* const cfg = "--target=generic-gnu --enable-vp9-highbitdepth --enable-external-build --enable-postproc --enable-multi-res-encoding --enable-temporal-denoising --enable-vp9-temporal-denoising --enable-vp9-postproc --size-limit=16384x16384 --enable-realtime-only --disable-install-docs --disable-libyuv"; +const char *vpx_codec_build_config(void) {return cfg;} -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_config.h ++++ chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_config.h @@ -0,0 +1,116 @@ +/* Copyright (c) 2011 The WebM project authors. All Rights Reserved. */ +/* */ @@ -22231,10 +22208,10 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ +#define DECODE_WIDTH_LIMIT 16384 +#define DECODE_HEIGHT_LIMIT 16384 +#endif /* VPX_CONFIG_H */ -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h ++++ chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_dsp_rtcd.h @@ -0,0 +1,4128 @@ +// This file is generated. Do not edit. +#ifndef VPX_DSP_RTCD_H_ @@ -26364,10 +26341,10 @@ Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_ +#endif + +#endif -Index: chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h +Index: chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h =================================================================== --- /dev/null -+++ chromium-122.0.6261.128/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h ++++ chromium-134.0.6998.35/third_party/libvpx/source/config/linux/ppc64/vpx_scale_rtcd.h @@ -0,0 +1,96 @@ +// This file is generated. Do not edit. +#ifndef VPX_SCALE_RTCD_H_ @@ -26507,21 +26484,21 @@ This patch implements support for the PPC64 architecture on Linux hosts. util/misc/capture_context_test_util_linux.cc | 6 + 36 files changed, 932 insertions(+), 12 deletions(-) -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/CONTRIBUTORS +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/CONTRIBUTORS =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/CONTRIBUTORS -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/CONTRIBUTORS +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/CONTRIBUTORS ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/CONTRIBUTORS @@ -13,3 +13,5 @@ Mark Mentovai Robert Sesek Scott Graham Joshua Peraza +Shawn Anastasio +Timothy Pearson -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/minidump/minidump_context.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context.h -@@ -687,6 +687,70 @@ struct MinidumpContextRISCV64 { +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/minidump/minidump_context.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context.h +@@ -686,6 +686,70 @@ struct MinidumpContextRISCV64 { uint32_t fcsr; }; @@ -26592,10 +26569,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_c } // namespace crashpad #endif // CRASHPAD_MINIDUMP_MINIDUMP_CONTEXT_H_ -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc @@ -110,6 +110,13 @@ MinidumpContextWriter::CreateFromSnapsho break; } @@ -26610,7 +26587,7 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_c default: { LOG(ERROR) << "unknown context architecture " << context_snapshot->architecture; -@@ -601,5 +608,48 @@ size_t MinidumpContextRISCV64Writer::Con +@@ -605,5 +612,48 @@ size_t MinidumpContextRISCV64Writer::Con DCHECK_GE(state(), kStateFrozen); return sizeof(context_); } @@ -26659,10 +26636,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_c +} } // namespace crashpad -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context_writer.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context_writer.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/minidump/minidump_context_writer.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context_writer.h +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/minidump/minidump_context_writer.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context_writer.h @@ -413,6 +413,49 @@ class MinidumpContextRISCV64Writer final MinidumpContextRISCV64 context_; }; @@ -26713,11 +26690,11 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_c } // namespace crashpad #endif // CRASHPAD_MINIDUMP_MINIDUMP_CONTEXT_WRITER_H_ -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc -@@ -328,6 +328,21 @@ TYPED_TEST(MinidumpContextWriter, RISCV6 +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_context_writer_test.cc +@@ -322,6 +322,21 @@ TYPED_TEST(MinidumpContextWriter, RISCV6 TypeParam>(context, ExpectMinidumpContextRISCV64, kSeed); } @@ -26739,10 +26716,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_c } // namespace } // namespace test } // namespace crashpad -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/minidump/minidump_misc_info_writer.cc @@ -177,6 +177,8 @@ std::string MinidumpMiscInfoDebugBuildSt static constexpr char kCPU[] = "mips64"; #elif defined(ARCH_CPU_RISCV64) @@ -26752,11 +26729,11 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/minidump/minidump_m #else #error define kCPU for this CPU #endif -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/capture_memory.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/capture_memory.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/capture_memory.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/capture_memory.cc -@@ -122,6 +122,11 @@ void CaptureMemory::PointedToByContext(c +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/capture_memory.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/capture_memory.cc +@@ -123,6 +123,11 @@ void CaptureMemory::PointedToByContext(c for (size_t i = 0; i < std::size(context.riscv64->regs); ++i) { MaybeCaptureMemoryAround(delegate, context.riscv64->regs[i]); } @@ -26768,10 +26745,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/capture_me #else #error Port. #endif -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_architecture.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/cpu_architecture.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/cpu_architecture.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_architecture.h +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/cpu_architecture.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/cpu_architecture.h @@ -47,6 +47,9 @@ enum CPUArchitecture { //! \brief 64-bit RISC-V. @@ -26782,10 +26759,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_archit }; } // namespace crashpad -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_context.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/cpu_context.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/cpu_context.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_context.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/cpu_context.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/cpu_context.cc @@ -173,6 +173,8 @@ uint64_t CPUContext::InstructionPointer( return arm64->pc; case kCPUArchitectureRISCV64: @@ -26794,8 +26771,8 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_contex + return ppc64->nip; default: NOTREACHED(); - return ~0ull; -@@ -191,6 +193,8 @@ uint64_t CPUContext::StackPointer() cons + } +@@ -190,6 +192,8 @@ uint64_t CPUContext::StackPointer() cons return arm64->sp; case kCPUArchitectureRISCV64: return riscv64->regs[1]; @@ -26803,8 +26780,8 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_contex + return ppc64->regs[1]; default: NOTREACHED(); - return ~0ull; -@@ -231,6 +235,7 @@ bool CPUContext::Is64Bit() const { + } +@@ -226,6 +230,7 @@ bool CPUContext::Is64Bit() const { case kCPUArchitectureX86_64: case kCPUArchitectureARM64: case kCPUArchitectureMIPS64EL: @@ -26812,10 +26789,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_contex case kCPUArchitectureRISCV64: return true; case kCPUArchitectureX86: -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_context.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/cpu_context.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/cpu_context.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_context.h +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/cpu_context.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/cpu_context.h @@ -371,6 +371,24 @@ struct CPUContextRISCV64 { uint32_t fcsr; }; @@ -26849,10 +26826,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/cpu_contex }; }; -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/cpu_context_linux.h @@ -15,6 +15,7 @@ #ifndef CRASHPAD_SNAPSHOT_LINUX_CPU_CONTEXT_LINUX_H_ #define CRASHPAD_SNAPSHOT_LINUX_CPU_CONTEXT_LINUX_H_ @@ -26940,11 +26917,11 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/cpu_ } // namespace internal } // namespace crashpad -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc -@@ -195,12 +195,15 @@ void TestAgainstTarget(PtraceConnection* +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/debug_rendezvous_test.cc +@@ -194,12 +194,15 @@ void TestAgainstTarget(PtraceConnection* device == 0 && inode == 0 && mapping_name == "[vdso]"; #if defined(ARCH_CPU_X86) static constexpr char kPrefix[] = "linux-gate.so."; @@ -26961,10 +26938,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/debu }, module_mapping->name, module_mapping->device, -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.cc @@ -367,6 +367,69 @@ bool ExceptionSnapshotLinux::ReadContext return internal::ReadContext(reader, context_address, context_.riscv64); } @@ -27035,11 +27012,11 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exce #endif // ARCH_CPU_X86_FAMILY bool ExceptionSnapshotLinux::Initialize( -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h -@@ -91,6 +91,8 @@ class ExceptionSnapshotLinux final : pub +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux.h +@@ -94,6 +94,8 @@ class ExceptionSnapshotLinux final : pub CPUContextMIPS64 mips64; #elif defined(ARCH_CPU_RISCV64) CPUContextRISCV64 riscv64; @@ -27048,10 +27025,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exce #endif } context_union_; CPUContext context_; -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/exception_snapshot_linux_test.cc @@ -325,7 +325,28 @@ void ExpectContext(const CPUContext& act sizeof(actual.riscv64->fpregs)), 0); @@ -27081,10 +27058,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/exce #else #error Port. #endif -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/process_reader_linux.cc @@ -129,6 +129,8 @@ void ProcessReaderLinux::Thread::Initial : thread_info.thread_context.t32.regs[29]; #elif defined(ARCH_CPU_RISCV64) @@ -27094,10 +27071,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/proc #else #error Port. #endif -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/signal_context.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/signal_context.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/snapshot/linux/signal_context.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/snapshot/linux/signal_context.h +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/snapshot/linux/signal_context.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/snapshot/linux/signal_context.h @@ -456,6 +456,89 @@ static_assert(offsetof(UContextthread_context, &info->thread_specific_data_address, -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/linux/thread_info.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/util/linux/thread_info.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/util/linux/thread_info.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/util/linux/thread_info.h +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/util/linux/thread_info.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/util/linux/thread_info.h @@ -34,6 +34,10 @@ #include #endif @@ -27480,10 +27457,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/linux/thread_i //! \brief The thread-local storage address for the thread. LinuxVMAddress thread_specific_data_address; }; -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context.h +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/util/misc/capture_context.h -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context.h +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/util/misc/capture_context.h ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context.h @@ -70,6 +70,7 @@ using NativeCPUContext = ucontext_t; //! Linux | ARM/ARM64 | `r0`/`x0` //! Linux | MIPS/MIPS64 | `$a0` @@ -27492,10 +27469,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_c //! //! Additionally, the value `LR` on ARM/ARM64 will be the return address of //! this function. -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context_linux.S +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context_linux.S =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/util/misc/capture_context_linux.S -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context_linux.S +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/util/misc/capture_context_linux.S ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context_linux.S @@ -30,7 +30,7 @@ .globl CAPTURECONTEXT_SYMBOL2 #if defined(__i386__) || defined(__x86_64__) @@ -27722,10 +27699,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_c #elif defined(__riscv) #define MCONTEXT_GREGS_OFFSET 176 -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context_test.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context_test.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/util/misc/capture_context_test.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context_test.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/util/misc/capture_context_test.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context_test.cc @@ -48,7 +48,7 @@ void TestCaptureContext() { uintptr_t pc = ProgramCounterFromContext(context_1); @@ -27735,10 +27712,10 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_c // Sanitizers can cause enough code bloat that the “nearby” check would // likely fail. const uintptr_t kReferencePC = -Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc +Index: chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc =================================================================== ---- chromium-122.0.6261.128.orig/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc -+++ chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc +--- chromium-134.0.6998.35.orig/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc ++++ chromium-134.0.6998.35/third_party/crashpad/crashpad/util/misc/capture_context_test_util_linux.cc @@ -38,6 +38,8 @@ void SanityCheckContext(const NativeCPUC #elif defined(ARCH_CPU_RISCV64) EXPECT_EQ(context.uc_mcontext.__gregs[10], @@ -27768,11 +27745,11 @@ Index: chromium-122.0.6261.128/third_party/crashpad/crashpad/util/misc/capture_c kIndex: chromium-114.0.5735.45/base/allocator/partition_allocator/partition_alloc.gni =================================================================== -Index: chromium-122.0.6261.128/base/allocator/partition_allocator/partition_alloc.gni +Index: chromium-134.0.6998.35/base/allocator/partition_allocator/partition_alloc.gni =================================================================== ---- chromium-122.0.6261.128.orig/base/allocator/partition_allocator/partition_alloc.gni -+++ chromium-122.0.6261.128/base/allocator/partition_allocator/partition_alloc.gni -@@ -21,7 +21,8 @@ if (is_nacl) { +--- chromium-134.0.6998.35.orig/base/allocator/partition_allocator/partition_alloc.gni ++++ chromium-134.0.6998.35/base/allocator/partition_allocator/partition_alloc.gni +@@ -69,7 +69,8 @@ if (is_nacl) { # NaCl targets don't use 64-bit pointers. has_64_bit_pointers = false } else if (current_cpu == "x64" || current_cpu == "arm64" || @@ -27782,117 +27759,27 @@ Index: chromium-122.0.6261.128/base/allocator/partition_allocator/partition_allo has_64_bit_pointers = true } else if (current_cpu == "x86" || current_cpu == "arm") { has_64_bit_pointers = false -Index: chromium-122.0.6261.128/third_party/highway/BUILD.gn +Index: chromium-134.0.6998.35/base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h =================================================================== ---- chromium-122.0.6261.128.orig/third_party/highway/BUILD.gn -+++ chromium-122.0.6261.128/third_party/highway/BUILD.gn -@@ -13,6 +13,9 @@ config("libhwy_external_config") { - # explicitly disabling AVX2 and AVX3 targets. - defines += [ "HWY_BROKEN_TARGETS=(HWY_AVX2|HWY_AVX3)" ] - } -+ if (target_cpu == "ppc64") { -+ defines += [ "TOOLCHAIN_MISS_ASM_HWCAP_H" ] -+ } - } - - source_set("libhwy") { -Index: chromium-122.0.6261.128/base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h -=================================================================== ---- chromium-122.0.6261.128.orig/base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h -+++ chromium-122.0.6261.128/base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h -@@ -173,7 +173,11 @@ SystemPageBaseMask() { +--- chromium-134.0.6998.35.orig/base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h ++++ chromium-134.0.6998.35/base/allocator/partition_allocator/src/partition_alloc/page_allocator_constants.h +@@ -209,7 +209,11 @@ SystemPageBaseMask() { return ~SystemPageOffsetMask(); } -+#if defined(ARCH_CPU_PPC64) ++#if PA_BUILDFLAG(PA_ARCH_CPU_PPC64_FAMILY) +constexpr size_t kPageMetadataShift = 6; // 64 bytes per partition page. +#else constexpr size_t kPageMetadataShift = 5; // 32 bytes per partition page. +#endif constexpr size_t kPageMetadataSize = 1 << kPageMetadataShift; - } // namespace partition_alloc::internal -Index: chromium-122.0.6261.128/base/allocator/partition_allocator/src/partition_alloc/partition_page.h + } // namespace internal +Index: chromium-134.0.6998.35/third_party/dawn/src/dawn/common/Platform.h =================================================================== ---- chromium-122.0.6261.128.orig/base/allocator/partition_allocator/src/partition_alloc/partition_page.h -+++ chromium-122.0.6261.128/base/allocator/partition_allocator/src/partition_alloc/partition_page.h -@@ -86,7 +86,11 @@ struct SlotSpanMetadata { - - // CHECK()ed in AllocNewSlotSpan(). - // The maximum number of bits needed to cover all currently supported OSes. -+#if defined(ARCH_CPU_PPC64) -+ static constexpr size_t kMaxSlotsPerSlotSpanBits = 15; -+#else - static constexpr size_t kMaxSlotsPerSlotSpanBits = 13; -+#endif - static_assert(kMaxSlotsPerSlotSpan < (1 << kMaxSlotsPerSlotSpanBits), ""); - - // |marked_full| isn't equivalent to being full. Slot span is marked as full -@@ -100,7 +104,11 @@ struct SlotSpanMetadata { - private: - const uint32_t can_store_raw_size_ : 1; - uint32_t freelist_is_sorted_ : 1; -+#if defined(ARCH_CPU_PPC64) -+ uint32_t unused1_ : (64 - 1 - 2 * kMaxSlotsPerSlotSpanBits - 1 - 1); -+#else - uint32_t unused1_ : (32 - 1 - 2 * kMaxSlotsPerSlotSpanBits - 1 - 1); -+#endif - // If |in_empty_cache_|==1, |empty_cache_index| is undefined and mustn't be - // used. - uint16_t in_empty_cache_ : 1; -Index: chromium-122.0.6261.128/base/allocator/partition_allocator/src/partition_alloc/partition_page_constants.h -=================================================================== ---- chromium-122.0.6261.128.orig/base/allocator/partition_allocator/src/partition_alloc/partition_page_constants.h -+++ chromium-122.0.6261.128/base/allocator/partition_allocator/src/partition_alloc/partition_page_constants.h -@@ -21,6 +21,11 @@ static constexpr size_t kMaxSlotsPerSlot - // currently (kMaxSlotsPerSlotSpanBits == 13) not supported by the code, - // so we use the 16 kiB maximum (64 kiB will crash). - static constexpr size_t kMaxSlotsPerSlotSpan = 4 * (1 << 14) / kSmallestBucket; -+#elif BUILDFLAG(IS_LINUX) && defined(ARCH_CPU_PPC64) -+// System page size is not a constant on OpenPOWER systems, but is either 4kiB -+// or 64kiB (1 << 12 or 1 << 16) -+// And PartitionPageSize() is 4 times the OS page size. -+static constexpr size_t kMaxSlotsPerSlotSpan = 4 * (1 << 16) / kSmallestBucket; - #else - // A slot span can "span" multiple PartitionPages, but then its slot size is - // larger, so it doesn't have as many slots. -Index: chromium-122.0.6261.128/third_party/dawn/src/dawn/common/Platform.h -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/dawn/src/dawn/common/Platform.h -+++ chromium-122.0.6261.128/third_party/dawn/src/dawn/common/Platform.h -@@ -153,9 +153,9 @@ - #define DAWN_PLATFORM_IS_MIPS64 1 - #endif - --#elif defiend(__s390__) -+#elif defined(__s390__) - #define DAWN_PLATFORM_IS_S390 1 --#elif defiend(__s390x__) -+#elif defined(__s390x__) - #define DAWN_PLATFORM_IS_S390X 1 - - #elif defined(__PPC__) -Index: chromium-122.0.6261.128/third_party/dawn/src/dawn/common/Assert.cpp -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/dawn/src/dawn/common/Assert.cpp -+++ chromium-122.0.6261.128/third_party/dawn/src/dawn/common/Assert.cpp -@@ -52,9 +52,9 @@ void BreakPoint() { - __asm__ __volatile__("ebreak"); - #elif DAWN_PLATFORM_IS(MIPS) - __asm__ __volatile__("break"); --#elif DAWN_PLATFORM_IS(S390) || DAWN_PLATFORM_IS_(S390X) -+#elif DAWN_PLATFORM_IS(S390) || DAWN_PLATFORM_IS(S390X) - __asm__ __volatile__(".word 0x0001"); --#elif DAWN_PLATFORM_IS(PPC) || DAWN_PLATFORM_IS_(PPC64) -+#elif DAWN_PLATFORM_IS(PPC) || DAWN_PLATFORM_IS(PPC64) - __asm__ __volatile__("twge 2,2"); - #else - #error "Unsupported platform" -Index: chromium-122.0.6261.128/third_party/dawn/src/dawn/common/Platform.h -=================================================================== ---- chromium-122.0.6261.128.orig/third_party/dawn/src/dawn/common/Platform.h -+++ chromium-122.0.6261.128/third_party/dawn/src/dawn/common/Platform.h -@@ -158,10 +158,12 @@ +--- chromium-134.0.6998.35.orig/third_party/dawn/src/dawn/common/Platform.h ++++ chromium-134.0.6998.35/third_party/dawn/src/dawn/common/Platform.h +@@ -159,10 +159,12 @@ #elif defined(__s390x__) #define DAWN_PLATFORM_IS_S390X 1 @@ -27905,5 +27792,101 @@ Index: chromium-122.0.6261.128/third_party/dawn/src/dawn/common/Platform.h +#elif defined(__PPC__) +#define DAWN_PLATFORM_IS_PPC 1 + #elif defined(__wasm32__) + #define DAWN_PLATFORM_IS_WASM32 1 +Index: chromium-134.0.6998.35/base/process/launch.h +=================================================================== +--- chromium-134.0.6998.35.orig/base/process/launch.h ++++ chromium-134.0.6998.35/base/process/launch.h +@@ -58,6 +58,9 @@ namespace base { + #if defined(ARCH_CPU_ARM64) + #define PTHREAD_STACK_MIN_CONST \ + (__builtin_constant_p(PTHREAD_STACK_MIN) ? PTHREAD_STACK_MIN : 131072) ++#elif defined(ARCH_CPU_PPC64) ++#define PTHREAD_STACK_MIN_CONST \ ++ (__builtin_constant_p(PTHREAD_STACK_MIN) ? PTHREAD_STACK_MIN : 131072) #else - #error "Unsupported platform." + #define PTHREAD_STACK_MIN_CONST \ + (__builtin_constant_p(PTHREAD_STACK_MIN) ? PTHREAD_STACK_MIN : 16384) +diff -up chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc.orig chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc +--- chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc.orig 2025-09-28 16:56:19.438134010 +0200 ++++ chromium/sandbox/linux/seccomp-bpf-helpers/syscall_parameters_restrictions.cc 2025-09-28 16:56:51.790767660 +0200 +@@ -41,7 +41,7 @@ + #endif + + #if (BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS_LACROS)) && \ +- !defined(__arm__) && !defined(__aarch64__) && \ ++ !defined(__arm__) && !defined(__aarch64__) && !defined(__powerpc64__) && \ + !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. +diff -up chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc.orig chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc +--- chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc.orig 2025-09-28 16:58:22.853176446 +0200 ++++ chromium/sandbox/linux/seccomp-bpf-helpers/syscall_sets.cc 2025-09-28 17:28:40.653091370 +0200 +@@ -621,18 +621,19 @@ bool SyscallSets::IsAllowedGeneralIo(int + case __NR_readv: + case __NR_pread64: + #if defined(__arm__) || \ +- (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) ++ (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \ ++ defined(__powerpc64__) + case __NR_recv: + #endif + #if defined(__x86_64__) || defined(__arm__) || defined(__mips__) || \ +- defined(__aarch64__) ++ defined(__aarch64__) || defined(__powerpc64__) + case __NR_recvfrom: // Could specify source. + case __NR_recvmsg: // Could specify source. + #endif +-#if defined(__i386__) || defined(__x86_64__) ++#if defined(__i386__) || defined(__x86_64__) || defined(__powerpc64__) + case __NR_select: + #endif +-#if defined(__i386__) || defined(__arm__) || defined(__mips__) ++#if defined(__i386__) || defined(__arm__) || defined(__mips__) || defined(__powerpc64__) + case __NR__newselect: + #endif + case __NR_write: +@@ -649,11 +650,12 @@ bool SyscallSets::IsAllowedGeneralIo(int + #endif + // send* syscalls need their flags filtered. + #if defined(__arm__) || \ +- (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) ++ (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \ ++ defined(__powerpc64__) + case __NR_send: + #endif + #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \ +- defined(__mips__) || defined(__aarch64__) ++ defined(__mips__) || defined(__aarch64__) || defined(__powerpc64__) + case __NR_sendmsg: // Could specify destination. + case __NR_sendto: // Could specify destination. + #endif +@@ -666,11 +668,12 @@ bool SyscallSets::IsAllowedGeneralIo(int + bool SyscallSets::IsSockSendOneMsg(int sysno) { + switch (sysno) { + #if defined(__arm__) || \ +- (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) ++ (defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)) || \ ++ defined(__powerpc64__) + case __NR_send: + #endif + #if defined(__i386__) || defined(__x86_64__) || defined(__arm__) || \ +- defined(__mips__) || defined(__aarch64__) ++ defined(__mips__) || defined(__aarch64__) || defined(__powerpc64__) + case __NR_sendmsg: // Could specify destination. + case __NR_sendto: // Could specify destination. + #endif +Index: chromium-134.0.6998.35/third_party/highway/src/hwy/targets.cc +=================================================================== +--- chromium-134.0.6998.35.orig/third_party/highway/src/hwy/targets.cc ++++ chromium-134.0.6998.35/third_party/highway/src/hwy/targets.cc +@@ -35,7 +35,7 @@ + HWY_OS_LINUX + // sys/auxv.h does not always include asm/hwcap.h, or define HWCAP*, hence we + // still include this directly. See #1199. +-#ifndef TOOLCHAIN_MISS_ASM_HWCAP_H ++#if !defined(TOOLCHAIN_MISS_ASM_HWCAP_H) && !defined(HWY_ARCH_PPC) + #include + #endif + #if HWY_HAVE_AUXV diff --git a/qtwebengine-fix-arm-build.patch b/qtwebengine-fix-arm-build.patch index 123ddac..5013750 100644 --- a/qtwebengine-fix-arm-build.patch +++ b/qtwebengine-fix-arm-build.patch @@ -1,9 +1,9 @@ diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt -index fe4f2c3f1..729d4d3e9 100644 +index d5e9b715e..af4c046c4 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt -@@ -544,6 +544,10 @@ foreach(arch ${archs}) - ) +@@ -570,6 +570,10 @@ foreach(arch ${archs}) + list(APPEND gnArgArg libyuv_use_sve=false) endif() endif() + if(cpu MATCHES "arm.*") @@ -12,3 +12,4 @@ index fe4f2c3f1..729d4d3e9 100644 + endif() unset(cpu) endif() + diff --git a/qtwebengine-fix-build-against-gcc16.patch b/qtwebengine-fix-build-against-gcc16.patch new file mode 100644 index 0000000..ad97de9 --- /dev/null +++ b/qtwebengine-fix-build-against-gcc16.patch @@ -0,0 +1,12 @@ +diff --git a/src/3rdparty/chromium/base/strings/to_string.h b/src/3rdparty/chromium/base/strings/to_string.h +index 96e61daa9e..5d097946f7 100644 +--- a/src/3rdparty/chromium/base/strings/to_string.h ++++ b/src/3rdparty/chromium/base/strings/to_string.h +@@ -6,6 +6,7 @@ + #define BASE_STRINGS_TO_STRING_H_ + + #include ++#include + #include + #include + #include diff --git a/qtwebengine-fix-build.patch b/qtwebengine-fix-build.patch deleted file mode 100644 index 20233bc..0000000 --- a/qtwebengine-fix-build.patch +++ /dev/null @@ -1,227 +0,0 @@ -diff --git a/src/3rdparty/chromium/base/debug/profiler.h b/src/3rdparty/chromium/base/debug/profiler.h -index 035affc..d8e1a53 100644 ---- a/src/3rdparty/chromium/base/debug/profiler.h -+++ b/src/3rdparty/chromium/base/debug/profiler.h -@@ -5,6 +5,7 @@ - #ifndef BASE_DEBUG_PROFILER_H_ - #define BASE_DEBUG_PROFILER_H_ - -+#include - #include - #include - -diff --git a/src/3rdparty/chromium/cc/trees/target_property.cc b/src/3rdparty/chromium/cc/trees/target_property.cc -index 7d73467..be4febd 100644 ---- a/src/3rdparty/chromium/cc/trees/target_property.cc -+++ b/src/3rdparty/chromium/cc/trees/target_property.cc -@@ -8,6 +8,8 @@ - - #include "ui/gfx/animation/keyframe/target_property.h" - -+#include -+ - namespace cc { - - static_assert(TargetProperty::LAST_TARGET_PROPERTY < -diff --git a/src/3rdparty/chromium/device/base/synchronization/one_writer_seqlock.cc b/src/3rdparty/chromium/device/base/synchronization/one_writer_seqlock.cc -index c62a00e..af54520 100644 ---- a/src/3rdparty/chromium/device/base/synchronization/one_writer_seqlock.cc -+++ b/src/3rdparty/chromium/device/base/synchronization/one_writer_seqlock.cc -@@ -6,6 +6,8 @@ - - #include "base/threading/platform_thread.h" - -+#include -+ - namespace device { - - OneWriterSeqLock::OneWriterSeqLock() : sequence_(0) {} -diff --git a/src/3rdparty/chromium/extensions/common/constants.h b/src/3rdparty/chromium/extensions/common/constants.h -index b5823c7..c152482 100644 ---- a/src/3rdparty/chromium/extensions/common/constants.h -+++ b/src/3rdparty/chromium/extensions/common/constants.h -@@ -13,6 +13,8 @@ - #include "build/chromeos_buildflags.h" - #include "extensions/common/extensions_export.h" - -+#include -+ - namespace extensions { - - // Scheme we serve extension content from. -diff --git a/src/3rdparty/chromium/gpu/config/gpu_util.h b/src/3rdparty/chromium/gpu/config/gpu_util.h -index 8edbfbe..467ebd6 100644 ---- a/src/3rdparty/chromium/gpu/config/gpu_util.h -+++ b/src/3rdparty/chromium/gpu/config/gpu_util.h -@@ -5,6 +5,8 @@ - #ifndef GPU_CONFIG_GPU_UTIL_H_ - #define GPU_CONFIG_GPU_UTIL_H_ - -+#include -+ - #include "build/build_config.h" - #include "gpu/config/gpu_feature_info.h" - #include "gpu/gpu_export.h" -diff --git a/src/3rdparty/chromium/net/base/parse_number.h b/src/3rdparty/chromium/net/base/parse_number.h -index f70619a..5c4eee7 100644 ---- a/src/3rdparty/chromium/net/base/parse_number.h -+++ b/src/3rdparty/chromium/net/base/parse_number.h -@@ -10,6 +10,8 @@ - - #include "net/base/net_export.h" - -+#include -+ - // This file contains utility functions for parsing numbers, in the context of - // network protocols. - // -diff --git a/src/3rdparty/chromium/ppapi/utility/completion_callback_factory_thread_traits.h b/src/3rdparty/chromium/ppapi/utility/completion_callback_factory_thread_traits.h -index 7c0dcde..97054d4 100644 ---- a/src/3rdparty/chromium/ppapi/utility/completion_callback_factory_thread_traits.h -+++ b/src/3rdparty/chromium/ppapi/utility/completion_callback_factory_thread_traits.h -@@ -38,6 +38,10 @@ namespace pp { - /// As a further optimization, we can add support for this later. - class ThreadSafeThreadTraits { - public: -+ -+ typedef pp::Lock Lock; -+ typedef pp::AutoLock AutoLock; -+ - class RefCount { - public: - /// Default constructor. In debug mode, this checks that the object is being -@@ -67,8 +71,6 @@ class ThreadSafeThreadTraits { - int32_t ref_; - }; - -- typedef pp::Lock Lock; -- typedef pp::AutoLock AutoLock; - }; - - /// The non-thread-safe version of thread traits. Using this class as the -diff --git a/src/3rdparty/chromium/third_party/dawn/src/dawn/native/CacheKey.h b/src/3rdparty/chromium/third_party/dawn/src/dawn/native/CacheKey.h -index a65ea9a..ba967c0 100644 ---- a/src/3rdparty/chromium/third_party/dawn/src/dawn/native/CacheKey.h -+++ b/src/3rdparty/chromium/third_party/dawn/src/dawn/native/CacheKey.h -@@ -28,6 +28,7 @@ - #ifndef SRC_DAWN_NATIVE_CACHEKEY_H_ - #define SRC_DAWN_NATIVE_CACHEKEY_H_ - -+#include - #include - - #include "dawn/native/stream/ByteVectorSink.h" -diff --git a/src/3rdparty/chromium/third_party/libgav1/src/src/utils/threadpool.cc b/src/3rdparty/chromium/third_party/libgav1/src/src/utils/threadpool.cc -index 6fa2e88..6b942ab 100644 ---- a/src/3rdparty/chromium/third_party/libgav1/src/src/utils/threadpool.cc -+++ b/src/3rdparty/chromium/third_party/libgav1/src/src/utils/threadpool.cc -@@ -31,6 +31,7 @@ - #include - #include - #include -+#include - #include - #include - -diff --git a/src/3rdparty/chromium/third_party/perfetto/src/trace_processor/importers/proto/proto_importer_module.h b/src/3rdparty/chromium/third_party/perfetto/src/trace_processor/importers/proto/proto_importer_module.h -index cc2c3a2..8eb694e 100644 ---- a/src/3rdparty/chromium/third_party/perfetto/src/trace_processor/importers/proto/proto_importer_module.h -+++ b/src/3rdparty/chromium/third_party/perfetto/src/trace_processor/importers/proto/proto_importer_module.h -@@ -22,6 +22,8 @@ - #include "perfetto/base/status.h" - #include "src/trace_processor/importers/common/trace_parser.h" - -+#include -+ - namespace perfetto { - - namespace protos { -diff --git a/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp b/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp -index ae6a412..5fe0370 100644 ---- a/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp -+++ b/src/3rdparty/chromium/third_party/skia/src/utils/SkParseColor.cpp -@@ -15,6 +15,10 @@ - #include - #include - -+#include -+#include -+#include -+ - static constexpr const char* gColorNames[] = { - "aliceblue", - "antiquewhite", -diff --git a/src/3rdparty/chromium/third_party/vulkan_memory_allocator/include/vk_mem_alloc.h b/src/3rdparty/chromium/third_party/vulkan_memory_allocator/include/vk_mem_alloc.h -index 0bbfeed..91f19f8 100644 ---- a/src/3rdparty/chromium/third_party/vulkan_memory_allocator/include/vk_mem_alloc.h -+++ b/src/3rdparty/chromium/third_party/vulkan_memory_allocator/include/vk_mem_alloc.h -@@ -122,6 +122,8 @@ See documentation chapter: \ref statistics. - */ - - -+#include -+ - #ifdef __cplusplus - extern "C" { - #endif -diff --git a/src/3rdparty/chromium/third_party/webrtc/modules/portal/xdg_session_details.h b/src/3rdparty/chromium/third_party/webrtc/modules/portal/xdg_session_details.h -index ab52508..050229a 100644 ---- a/src/3rdparty/chromium/third_party/webrtc/modules/portal/xdg_session_details.h -+++ b/src/3rdparty/chromium/third_party/webrtc/modules/portal/xdg_session_details.h -@@ -13,6 +13,7 @@ - - #include - -+#include - #include - - namespace webrtc { -diff --git a/src/3rdparty/chromium/ui/events/gesture_event_details.h b/src/3rdparty/chromium/ui/events/gesture_event_details.h -index 857da97..e48e24d 100644 ---- a/src/3rdparty/chromium/ui/events/gesture_event_details.h -+++ b/src/3rdparty/chromium/ui/events/gesture_event_details.h -@@ -5,6 +5,7 @@ - #ifndef UI_EVENTS_GESTURE_EVENT_DETAILS_H_ - #define UI_EVENTS_GESTURE_EVENT_DETAILS_H_ - -+#include - #include - - #include "base/check_op.h" -diff --git a/src/3rdparty/chromium/ui/gfx/geometry/linear_gradient.h b/src/3rdparty/chromium/ui/gfx/geometry/linear_gradient.h -index 7239ed5..975b88c 100644 ---- a/src/3rdparty/chromium/ui/gfx/geometry/linear_gradient.h -+++ b/src/3rdparty/chromium/ui/gfx/geometry/linear_gradient.h -@@ -7,6 +7,7 @@ - - #include - -+#include - #include - #include - #include -diff --git a/src/3rdparty/chromium/v8/src/base/macros.h b/src/3rdparty/chromium/v8/src/base/macros.h -index 93a99ec..f6ddfe7 100644 ---- a/src/3rdparty/chromium/v8/src/base/macros.h -+++ b/src/3rdparty/chromium/v8/src/base/macros.h -@@ -5,6 +5,7 @@ - #ifndef V8_BASE_MACROS_H_ - #define V8_BASE_MACROS_H_ - -+#include - #include - #include - -diff --git a/src/core/browsing_data_remover_delegate_qt.h b/src/core/browsing_data_remover_delegate_qt.h -index d33af4a..ce864b6 100644 ---- a/src/core/browsing_data_remover_delegate_qt.h -+++ b/src/core/browsing_data_remover_delegate_qt.h -@@ -8,6 +8,8 @@ - - #include "content/public/browser/browsing_data_remover_delegate.h" - -+#include -+ - namespace QtWebEngineCore { - - class BrowsingDataRemoverDelegateQt : public content::BrowsingDataRemoverDelegate { diff --git a/qtwebengine-fix-building-system-ffmpeg.patch b/qtwebengine-fix-building-system-ffmpeg.patch deleted file mode 100644 index 40e2e97..0000000 --- a/qtwebengine-fix-building-system-ffmpeg.patch +++ /dev/null @@ -1,214 +0,0 @@ -From 24e9ff7caa6aa78c1c73e7329cf1230a455d0c1b Mon Sep 17 00:00:00 2001 -From: Martin Negyokru -Date: Fri, 17 Jan 2025 15:40:37 +0100 -Subject: [PATCH] [fixup][ffmpeg] Fix building with system ffmpeg - -Refactor workaround for codec selection issues. -Introduce FindDecoder which meant to replace avcodec_find_decoder. -Imporove codec detection in format context. - -Fixes: QTBUG-132762 -Task-number: QTBUG-130273 -Change-Id: I6d520633ebebbb9bdb7aa71b8247066c2a662be3 -Reviewed-on: https://codereview.qt-project.org/c/qt/qtwebengine-chromium/+/617873 -Reviewed-by: Moss Heim -Reviewed-by: Allan Sandfeld Jensen -(cherry picked from commit 54a756b84e0b7a1104f9b336a1253fe36c573f56) -Reviewed-on: https://codereview.qt-project.org/c/qt/qtwebengine-chromium/+/624054 ---- - -diff --git a/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc b/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc -index 9646e70..5b9a02e 100644 ---- a/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc -+++ b/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc -@@ -177,7 +177,12 @@ - if (codec_context_->sample_fmt == AV_SAMPLE_FMT_S16P) - codec_context_->request_sample_fmt = AV_SAMPLE_FMT_S16; - -+#if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -+ const AVCodec* codec = -+ FindDecoder(codec_context_->codec_id, codec_context_->codec_whitelist); -+#else - const AVCodec* codec = avcodec_find_decoder(codec_context_->codec_id); -+#endif - if (!codec || avcodec_open2(codec_context_.get(), codec, NULL) < 0) { - DLOG(ERROR) << "Could not initialize audio decoder: " - << codec_context_->codec_id; -diff --git a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -index 63159ef..f872a8e 100644 ---- a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -+++ b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -@@ -29,6 +29,11 @@ - #endif - #endif - -+#if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -+extern "C" { -+#include -+} -+#endif - namespace media { - - namespace { -@@ -67,6 +72,24 @@ - VideoFrame::kFrameAddressAlignment % kFFmpegBufferAddressAlignment == 0, - "VideoFrame frame address alignment does not fit ffmpeg requirement"); - -+#if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -+const AVCodec* FindDecoder(AVCodecID id, const char* whitelist) { -+ if (!whitelist) { -+ return avcodec_find_decoder(id); -+ } -+ -+ void* i = 0; -+ const AVCodec* codec; -+ while (codec = av_codec_iterate(&i)) { -+ if (av_codec_is_decoder(codec) && codec->id == id && -+ av_match_list(codec->name, whitelist, ',')) { -+ return codec; -+ } -+ } -+ return nullptr; -+} -+#endif -+ - static const AVRational kMicrosBase = { 1, base::Time::kMicrosecondsPerSecond }; - - base::TimeDelta ConvertFromTimeBase(const AVRational& time_base, -diff --git a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.h b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.h -index 9993d34..2332722 100644 ---- a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.h -+++ b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.h -@@ -79,6 +79,12 @@ - av_frame_free(&frame); - } - -+#if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -+// Systemlib friendly version of avcodec_find_decoder that respects the -+// whitelisted codecs. -+MEDIA_EXPORT const AVCodec* FindDecoder(AVCodecID id, const char* whitelist); -+#endif -+ - // Converts an int64_t timestamp in |time_base| units to a base::TimeDelta. - // For example if |timestamp| equals 11025 and |time_base| equals {1, 44100} - // then the return value will be a base::TimeDelta for 0.25 seconds since that -diff --git a/src/3rdparty/chromium/media/filters/audio_file_reader.cc b/src/3rdparty/chromium/media/filters/audio_file_reader.cc -index dd4f3b5..172bd9a 100644 ---- a/src/3rdparty/chromium/media/filters/audio_file_reader.cc -+++ b/src/3rdparty/chromium/media/filters/audio_file_reader.cc -@@ -95,7 +95,12 @@ - } - - bool AudioFileReader::OpenDecoder() { -+#if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -+ const AVCodec* codec = -+ FindDecoder(codec_context_->codec_id, codec_context_->codec_whitelist); -+#else - const AVCodec* codec = avcodec_find_decoder(codec_context_->codec_id); -+#endif - if (codec) { - // MP3 decodes to S16P which we don't support, tell it to use S16 instead. - if (codec_context_->sample_fmt == AV_SAMPLE_FMT_S16P) -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc b/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc -index 22fa4d48..5d94b76 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc -@@ -360,19 +360,8 @@ - } - - #if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -- // Workaround http://crbug.com/41492567 -- // Chromium only supports the 'libopus' decoder. -- // 'avcodec_find_decoder' finds the experimental 'opus' decoder first -- // because the lookup is based on codec_id and both have the same id. -- // Bundled ffmpeg only have libopus but the system usually have both. -- const AVCodec* codec = [&config, this]() { -- if (config.codec() == AudioCodec::kOpus) -- return avcodec_find_decoder_by_name("libopus"); -- if (config.codec() == AudioCodec::kMP3) { -- return avcodec_find_decoder_by_name("mp3"); -- } -- return avcodec_find_decoder(codec_context_->codec_id); -- }(); -+ AVCodecID id = AudioCodecToCodecID(config.codec(), config.sample_format()); -+ const AVCodec* codec = FindDecoder(id, codec_context_->codec_whitelist); - #else - const AVCodec* codec = avcodec_find_decoder(codec_context_->codec_id); - #endif -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_glue.cc b/src/3rdparty/chromium/media/filters/ffmpeg_glue.cc -index 6407b5b..e9bd44b 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_glue.cc -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_glue.cc -@@ -242,20 +242,27 @@ - LogContainer(is_local_file, container_); - - #if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -- // Sometimes FFmpeg is not aware of the whitelisted codecs and -- // configures streams and demuxers with unsupported codecs/params. -- // Force the correct codecs to avoid problems later. -+ // 'avformat_find_stream_info' is not aware of the whitelisted codecs. -+ // However it respects the codecs set in the format_context. -+ // Try to force the correct codecs here at context creation. - // https://ffmpeg.org/doxygen/7.0/structAVFormatContext.html#a52f39351b15890ef57cc6ff0ec9ab42d - // https://ffmpeg.org/doxygen/7.0/structAVFormatContext.html#ae5e087f4623b907517c0f7dd8327387d - -- // Note: don't forget to update FFmpeg[Audio|Video]Decoder::ConfigureDecoder -- -- if (strcmp(format_context_->iformat->name, "mp3") == 0) { -- const AVCodec* mp3_codec = avcodec_find_decoder_by_name("mp3"); -- if (mp3_codec) { -- format_context_->audio_codec = mp3_codec; -- } else { -- LOG(ERROR) << "No supported codec for mp3"; -+ for (int i = 0; i < format_context_->nb_streams; i++) { -+ AVCodecParameters *params = format_context_->streams[i]->codecpar; -+ if (!params) -+ continue; -+ const AVCodec* audio_codec = -+ FindDecoder(params->codec_id, GetAllowedAudioDecoders()); -+ if (audio_codec) { -+ if (format_context_->audio_codec && -+ format_context_->audio_codec != audio_codec) { -+ LOG(INFO) << "Conflicting codecs " << format_context_->audio_codec->name -+ << ", " << audio_codec->name; -+ format_context_->audio_codec = nullptr; -+ break; -+ } -+ format_context_->audio_codec = audio_codec; - } - } - #endif -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc b/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc -index d08ee1d..832a3fa 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc -@@ -524,7 +524,12 @@ - codec_context_->flags2 |= AV_CODEC_FLAG2_CHUNKS; - } - -+#if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -+ const AVCodec* codec = -+ FindDecoder(codec_context_->codec_id, codec_context_->codec_whitelist); -+#else - const AVCodec* codec = avcodec_find_decoder(codec_context_->codec_id); -+#endif - if (!codec || avcodec_open2(codec_context_.get(), codec, NULL) < 0) { - ReleaseFFmpegResources(); - return false; -diff --git a/src/3rdparty/chromium/media/filters/media_file_checker.cc b/src/3rdparty/chromium/media/filters/media_file_checker.cc -index a2d4757..afe40e4 100644 ---- a/src/3rdparty/chromium/media/filters/media_file_checker.cc -+++ b/src/3rdparty/chromium/media/filters/media_file_checker.cc -@@ -68,7 +68,12 @@ - auto context = AVStreamToAVCodecContext(format_context->streams[i]); - if (!context) - continue; -+#if BUILDFLAG(IS_QTWEBENGINE) && BUILDFLAG(USE_SYSTEM_FFMPEG) -+ const AVCodec* codec = -+ FindDecoder(cp->codec_id, context->codec_whitelist); -+#else - const AVCodec* codec = avcodec_find_decoder(cp->codec_id); -+#endif - if (codec && avcodec_open2(context.get(), codec, nullptr) >= 0) { - auto loop = std::make_unique(context.get()); - stream_contexts[i] = {std::move(context), std::move(loop)}; diff --git a/qtwebengine-fix-building-with-system-ffmpeg.patch b/qtwebengine-fix-building-with-system-ffmpeg.patch deleted file mode 100644 index 79a4b71..0000000 --- a/qtwebengine-fix-building-with-system-ffmpeg.patch +++ /dev/null @@ -1,574 +0,0 @@ -From 6e554a30893150793c2638e3689cf208ffc8e375 Mon Sep 17 00:00:00 2001 -From: Dale Curtis -Date: Sat, 2 Apr 2022 05:13:53 +0000 -Subject: [PATCH] Roll src/third_party/ffmpeg/ 574c39cce..32b2d1d526 (1125 - commits) - -https://chromium.googlesource.com/chromium/third_party/ffmpeg.git/+log/574c39cce323..32b2d1d526 - -Created with: - roll-dep src/third_party/ffmpeg - -Fixed: 1293918 -Cq-Include-Trybots: luci.chromium.try:mac_chromium_asan_rel_ng,linux_chromium_asan_rel_ng,linux_chromium_chromeos_asan_rel_ng -Change-Id: I41945d0f963e3d1f65940067bac22f63b68e37d2 -Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3565647 -Auto-Submit: Dale Curtis -Reviewed-by: Dan Sanders -Commit-Queue: Dale Curtis -Cr-Commit-Position: refs/heads/main@{#988253} ---- - .../clear_key_cdm/ffmpeg_cdm_audio_decoder.cc | 29 ++++++++++--------- - media/ffmpeg/ffmpeg_common.cc | 11 +++---- - media/filters/audio_file_reader.cc | 9 +++--- - media/filters/audio_file_reader_unittest.cc | 6 ++-- - .../filters/audio_video_metadata_extractor.cc | 11 +++++-- - .../filters/ffmpeg_aac_bitstream_converter.cc | 7 +++-- - ...ffmpeg_aac_bitstream_converter_unittest.cc | 2 +- - media/filters/ffmpeg_audio_decoder.cc | 13 +++++---- - 8 files changed, 51 insertions(+), 37 deletions(-) - -diff --git a/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc b/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc -index c535d2b..62ddbc8 100644 ---- a/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc -+++ b/src/3rdparty/chromium/media/cdm/library_cdm/clear_key_cdm/ffmpeg_cdm_audio_decoder.cc -@@ -74,7 +74,7 @@ void CdmAudioDecoderConfigToAVCodecContext( - codec_context->sample_fmt = AV_SAMPLE_FMT_NONE; - } - -- codec_context->channels = config.channel_count; -+ codec_context->ch_layout.nb_channels = config.channel_count; - codec_context->sample_rate = config.samples_per_second; - - if (config.extra_data) { -@@ -124,8 +124,8 @@ void CopySamples(cdm::AudioFormat cdm_format, - case cdm::kAudioFormatPlanarS16: - case cdm::kAudioFormatPlanarF32: { - const int decoded_size_per_channel = -- decoded_audio_size / av_frame.channels; -- for (int i = 0; i < av_frame.channels; ++i) { -+ decoded_audio_size / av_frame.ch_layout.nb_channels; -+ for (int i = 0; i < av_frame.ch_layout.nb_channels; ++i) { - memcpy(output_buffer, av_frame.extended_data[i], - decoded_size_per_channel); - output_buffer += decoded_size_per_channel; -@@ -185,13 +185,14 @@ bool FFmpegCdmAudioDecoder::Initialize( - // Success! - decoding_loop_ = std::make_unique(codec_context_.get()); - samples_per_second_ = config.samples_per_second; -- bytes_per_frame_ = codec_context_->channels * config.bits_per_channel / 8; -+ bytes_per_frame_ = -+ codec_context_->ch_layout.nb_channels * config.bits_per_channel / 8; - output_timestamp_helper_ = - std::make_unique(config.samples_per_second); - is_initialized_ = true; - - // Store initial values to guard against midstream configuration changes. -- channels_ = codec_context_->channels; -+ channels_ = codec_context_->ch_layout.nb_channels; - av_sample_format_ = codec_context_->sample_fmt; - - return true; -@@ -291,7 +292,8 @@ cdm::Status FFmpegCdmAudioDecoder::DecodeBuffer( - for (auto& frame : audio_frames) { - int decoded_audio_size = 0; - if (frame->sample_rate != samples_per_second_ || -- frame->channels != channels_ || frame->format != av_sample_format_) { -+ frame->ch_layout.nb_channels != channels_ || -+ frame->format != av_sample_format_) { - DLOG(ERROR) << "Unsupported midstream configuration change!" - << " Sample Rate: " << frame->sample_rate << " vs " - << samples_per_second_ -@@ -302,7 +304,7 @@ cdm::Status FFmpegCdmAudioDecoder::DecodeBuffer( - } - - decoded_audio_size = av_samples_get_buffer_size( -- nullptr, codec_context_->channels, frame->nb_samples, -+ nullptr, codec_context_->ch_layout.nb_channels, frame->nb_samples, - codec_context_->sample_fmt, 1); - if (!decoded_audio_size) - continue; -@@ -322,7 +324,7 @@ bool FFmpegCdmAudioDecoder::OnNewFrame( - std::vector>* audio_frames, - AVFrame* frame) { - *total_size += av_samples_get_buffer_size( -- nullptr, codec_context_->channels, frame->nb_samples, -+ nullptr, codec_context_->ch_layout.nb_channels, frame->nb_samples, - codec_context_->sample_fmt, 1); - audio_frames->emplace_back(av_frame_clone(frame)); - return true; -diff --git a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -index 2665355..910f9ad 100644 ---- a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -+++ b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -@@ -336,10 +336,11 @@ bool AVCodecContextToAudioDecoderConfig(const AVCodecContext* codec_context, - codec_context->sample_fmt, codec_context->codec_id); - - ChannelLayout channel_layout = -- codec_context->channels > 8 -+ codec_context->ch_layout.nb_channels > 8 - ? CHANNEL_LAYOUT_DISCRETE -- : ChannelLayoutToChromeChannelLayout(codec_context->channel_layout, -- codec_context->channels); -+ : ChannelLayoutToChromeChannelLayout( -+ codec_context->ch_layout.u.mask, -+ codec_context->ch_layout.nb_channels); - - switch (codec) { - // For AC3/EAC3 we enable only demuxing, but not decoding, so FFmpeg does -@@ -391,7 +392,7 @@ bool AVCodecContextToAudioDecoderConfig(const AVCodecContext* codec_context, - extra_data, encryption_scheme, seek_preroll, - codec_context->delay); - if (channel_layout == CHANNEL_LAYOUT_DISCRETE) -- config->SetChannelsForDiscrete(codec_context->channels); -+ config->SetChannelsForDiscrete(codec_context->ch_layout.nb_channels); - - #if BUILDFLAG(ENABLE_PLATFORM_AC3_EAC3_AUDIO) - // These are bitstream formats unknown to ffmpeg, so they don't have -@@ -460,7 +461,7 @@ void AudioDecoderConfigToAVCodecContext(const AudioDecoderConfig& config, - - // TODO(scherkus): should we set |channel_layout|? I'm not sure if FFmpeg uses - // said information to decode. -- codec_context->channels = config.channels(); -+ codec_context->ch_layout.nb_channels = config.channels(); - codec_context->sample_rate = config.samples_per_second(); - - if (config.extra_data().empty()) { -diff --git a/src/3rdparty/chromium/media/filters/audio_file_reader.cc b/src/3rdparty/chromium/media/filters/audio_file_reader.cc -index 777eabc..2b58dd7 100644 ---- a/src/3rdparty/chromium/media/filters/audio_file_reader.cc -+++ b/src/3rdparty/chromium/media/filters/audio_file_reader.cc -@@ -113,14 +113,15 @@ bool AudioFileReader::OpenDecoder() { - - // Verify the channel layout is supported by Chrome. Acts as a sanity check - // against invalid files. See http://crbug.com/171962 -- if (ChannelLayoutToChromeChannelLayout(codec_context_->channel_layout, -- codec_context_->channels) == -+ if (ChannelLayoutToChromeChannelLayout( -+ codec_context_->ch_layout.u.mask, -+ codec_context_->ch_layout.nb_channels) == - CHANNEL_LAYOUT_UNSUPPORTED) { - return false; - } - - // Store initial values to guard against midstream configuration changes. -- channels_ = codec_context_->channels; -+ channels_ = codec_context_->ch_layout.nb_channels; - audio_codec_ = CodecIDToAudioCodec(codec_context_->codec_id); - sample_rate_ = codec_context_->sample_rate; - av_sample_format_ = codec_context_->sample_fmt; -@@ -223,7 +224,7 @@ bool AudioFileReader::OnNewFrame( - if (frames_read < 0) - return false; - -- const int channels = frame->channels; -+ const int channels = frame->ch_layout.nb_channels; - if (frame->sample_rate != sample_rate_ || channels != channels_ || - frame->format != av_sample_format_) { - DLOG(ERROR) << "Unsupported midstream configuration change!" -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter.cc b/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter.cc -index 76b41aa..e26b6cd 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter.cc -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter.cc -@@ -195,14 +195,15 @@ bool FFmpegAACBitstreamConverter::ConvertPacket(AVPacket* packet) { - if (!header_generated_ || codec_ != stream_codec_parameters_->codec_id || - audio_profile_ != stream_codec_parameters_->profile || - sample_rate_index_ != sample_rate_index || -- channel_configuration_ != stream_codec_parameters_->channels || -+ channel_configuration_ != -+ stream_codec_parameters_->ch_layout.nb_channels || - frame_length_ != header_plus_packet_size) { - header_generated_ = - GenerateAdtsHeader(stream_codec_parameters_->codec_id, - 0, // layer - stream_codec_parameters_->profile, sample_rate_index, - 0, // private stream -- stream_codec_parameters_->channels, -+ stream_codec_parameters_->ch_layout.nb_channels, - 0, // originality - 0, // home - 0, // copyrighted_stream -@@ -214,7 +215,7 @@ bool FFmpegAACBitstreamConverter::ConvertPacket(AVPacket* packet) { - codec_ = stream_codec_parameters_->codec_id; - audio_profile_ = stream_codec_parameters_->profile; - sample_rate_index_ = sample_rate_index; -- channel_configuration_ = stream_codec_parameters_->channels; -+ channel_configuration_ = stream_codec_parameters_->ch_layout.nb_channels; - frame_length_ = header_plus_packet_size; - } - -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter_unittest.cc b/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter_unittest.cc -index 3b46f7f..1897eb0 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter_unittest.cc -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_aac_bitstream_converter_unittest.cc -@@ -34,7 +34,7 @@ class FFmpegAACBitstreamConverterTest : public testing::Test { - memset(&test_parameters_, 0, sizeof(AVCodecParameters)); - test_parameters_.codec_id = AV_CODEC_ID_AAC; - test_parameters_.profile = FF_PROFILE_AAC_MAIN; -- test_parameters_.channels = 2; -+ test_parameters_.ch_layout.nb_channels = 2; - test_parameters_.extradata = extradata_header_; - test_parameters_.extradata_size = sizeof(extradata_header_); - } -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc b/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc -index bf3ed00..d564ee9 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_audio_decoder.cc -@@ -29,7 +29,7 @@ namespace media { - - // Return the number of channels from the data in |frame|. - static inline int DetermineChannels(AVFrame* frame) { -- return frame->channels; -+ return frame->ch_layout.nb_channels; - } - - // Called by FFmpeg's allocation routine to allocate a buffer. Uses -@@ -243,7 +243,7 @@ bool FFmpegAudioDecoder::OnNewFrame(const DecoderBuffer& buffer, - // Translate unsupported into discrete layouts for discrete configurations; - // ffmpeg does not have a labeled discrete configuration internally. - ChannelLayout channel_layout = ChannelLayoutToChromeChannelLayout( -- codec_context_->channel_layout, codec_context_->channels); -+ codec_context_->ch_layout.u.mask, codec_context_->ch_layout.nb_channels); - if (channel_layout == CHANNEL_LAYOUT_UNSUPPORTED && - config_.channel_layout() == CHANNEL_LAYOUT_DISCRETE) { - channel_layout = CHANNEL_LAYOUT_DISCRETE; -@@ -360,11 +360,11 @@ bool FFmpegAudioDecoder::ConfigureDecoder(const AudioDecoderConfig& config) { - // Success! - av_sample_format_ = codec_context_->sample_fmt; - -- if (codec_context_->channels != config.channels()) { -+ if (codec_context_->ch_layout.nb_channels != config.channels()) { - MEDIA_LOG(ERROR, media_log_) - << "Audio configuration specified " << config.channels() - << " channels, but FFmpeg thinks the file contains " -- << codec_context_->channels << " channels"; -+ << codec_context_->ch_layout.nb_channels << " channels"; - ReleaseFFmpegResources(); - state_ = DecoderState::kUninitialized; - return false; -@@ -415,7 +415,7 @@ int FFmpegAudioDecoder::GetAudioBuffer(struct AVCodecContext* s, - if (frame->nb_samples <= 0) - return AVERROR(EINVAL); - -- if (s->channels != channels) { -+ if (s->ch_layout.nb_channels != channels) { - DLOG(ERROR) << "AVCodecContext and AVFrame disagree on channel count."; - return AVERROR(EINVAL); - } -@@ -448,7 +448,8 @@ int FFmpegAudioDecoder::GetAudioBuffer(struct AVCodecContext* s, - ChannelLayout channel_layout = - config_.channel_layout() == CHANNEL_LAYOUT_DISCRETE - ? CHANNEL_LAYOUT_DISCRETE -- : ChannelLayoutToChromeChannelLayout(s->channel_layout, s->channels); -+ : ChannelLayoutToChromeChannelLayout(s->ch_layout.u.mask, -+ s->ch_layout.nb_channels); - - if (channel_layout == CHANNEL_LAYOUT_UNSUPPORTED) { - DLOG(ERROR) << "Unsupported channel layout."; -commit 62274859104bd828373ae406aa9309e610449ac5 -Author: Ted Meyer -Date: Fri Mar 22 19:56:55 2024 +0000 - - Replace deprecated use of AVCodecContext::reordered_opaque - - We can use the AV_CODEC_FLAG_COPY_OPAQUE flag on the codec context - now to trigger timestamp propagation. - - Bug: 330573128 - Change-Id: I6bc57241a35ab5283742aad8d42acb4dc5e85858 - Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5384308 - Commit-Queue: Ted (Chromium) Meyer - Reviewed-by: Dan Sanders - Cr-Commit-Position: refs/heads/main@{#1277051} - -diff --git a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -index 910f9ad..8be165c 100644 ---- a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -+++ b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_common.cc -@@ -411,7 +411,9 @@ bool AVCodecContextToAudioDecoderConfig(const AVCodecContext* codec_context, - - // TODO(dalecurtis): Just use the profile from the codec context if ffmpeg - // ever starts supporting xHE-AAC. -- if (codec_context->profile == FF_PROFILE_UNKNOWN) { -+ constexpr uint8_t kXHEAAc = 41; -+ if (codec_context->profile == FF_PROFILE_UNKNOWN || -+ codec_context->profile == kXHEAAc) { - // Errors aren't fatal here, so just drop any MediaLog messages. - NullMediaLog media_log; - mp4::AAC aac_parser; -diff --git a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_regression_tests.cc b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_regression_tests.cc -index 05dcb1c..866f446 100644 ---- a/src/3rdparty/chromium/media/ffmpeg/ffmpeg_regression_tests.cc -+++ b/src/3rdparty/chromium/media/ffmpeg/ffmpeg_regression_tests.cc -@@ -90,16 +90,16 @@ FFMPEG_TEST_CASE(Cr62127, - PIPELINE_ERROR_DECODE, - PIPELINE_ERROR_DECODE); - FFMPEG_TEST_CASE(Cr93620, "security/93620.ogg", PIPELINE_OK, PIPELINE_OK); --FFMPEG_TEST_CASE(Cr100492, -- "security/100492.webm", -- DECODER_ERROR_NOT_SUPPORTED, -- DECODER_ERROR_NOT_SUPPORTED); -+FFMPEG_TEST_CASE(Cr100492, "security/100492.webm", PIPELINE_OK, PIPELINE_OK); - FFMPEG_TEST_CASE(Cr100543, "security/100543.webm", PIPELINE_OK, PIPELINE_OK); - FFMPEG_TEST_CASE(Cr101458, - "security/101458.webm", - PIPELINE_ERROR_DECODE, - PIPELINE_ERROR_DECODE); --FFMPEG_TEST_CASE(Cr108416, "security/108416.webm", PIPELINE_OK, PIPELINE_OK); -+FFMPEG_TEST_CASE(Cr108416, -+ "security/108416.webm", -+ PIPELINE_ERROR_DECODE, -+ PIPELINE_ERROR_DECODE); - FFMPEG_TEST_CASE(Cr110849, - "security/110849.mkv", - DEMUXER_ERROR_COULD_NOT_OPEN, -@@ -154,7 +154,10 @@ FFMPEG_TEST_CASE(Cr234630b, - "security/234630b.mov", - DEMUXER_ERROR_NO_SUPPORTED_STREAMS, - DEMUXER_ERROR_NO_SUPPORTED_STREAMS); --FFMPEG_TEST_CASE(Cr242786, "security/242786.webm", PIPELINE_OK, PIPELINE_OK); -+FFMPEG_TEST_CASE(Cr242786, -+ "security/242786.webm", -+ PIPELINE_OK, -+ PIPELINE_ERROR_DECODE); - // Test for out-of-bounds access with slightly corrupt file (detection logic - // thinks it's a MONO file, but actually contains STEREO audio). - FFMPEG_TEST_CASE(Cr275590, -@@ -372,8 +375,8 @@ FFMPEG_TEST_CASE(WEBM_2, - DEMUXER_ERROR_NO_SUPPORTED_STREAMS); - FFMPEG_TEST_CASE(WEBM_4, - "security/out.webm.68798.1929", -- DECODER_ERROR_NOT_SUPPORTED, -- DECODER_ERROR_NOT_SUPPORTED); -+ PIPELINE_OK, -+ PIPELINE_OK); - FFMPEG_TEST_CASE(WEBM_5, "frame_size_change.webm", PIPELINE_OK, PIPELINE_OK); - - // General MKV test cases. -diff --git a/src/3rdparty/chromium/media/filters/audio_decoder_unittest.cc b/src/3rdparty/chromium/media/filters/audio_decoder_unittest.cc -index a7b2533..ba3c308 100644 ---- a/src/3rdparty/chromium/media/filters/audio_decoder_unittest.cc -+++ b/src/3rdparty/chromium/media/filters/audio_decoder_unittest.cc -@@ -484,7 +484,7 @@ constexpr TestParams kXheAacTestParams[] = { - }}, - 0, - 29400, -- CHANNEL_LAYOUT_MONO, -+ CHANNEL_LAYOUT_UNSUPPORTED, - AudioCodecProfile::kXHE_AAC}, - #endif - {AudioCodec::kAAC, -diff --git a/src/3rdparty/chromium/media/filters/audio_file_reader.cc b/src/3rdparty/chromium/media/filters/audio_file_reader.cc -index 2b58dd7..9d37f32 100644 ---- a/src/3rdparty/chromium/media/filters/audio_file_reader.cc -+++ b/src/3rdparty/chromium/media/filters/audio_file_reader.cc -@@ -243,18 +243,10 @@ bool AudioFileReader::OnNewFrame( - // silence from being output. In the case where we are also discarding some - // portion of the packet (as indicated by a negative pts), we further want to - // adjust the duration downward by however much exists before zero. --#if BUILDFLAG(USE_SYSTEM_FFMPEG) -- if (audio_codec_ == AudioCodec::kAAC && frame->pkt_duration) { --#else - if (audio_codec_ == AudioCodec::kAAC && frame->duration) { --#endif // BUILDFLAG(USE_SYSTEM_FFMPEG) - const base::TimeDelta pkt_duration = ConvertFromTimeBase( - glue_->format_context()->streams[stream_index_]->time_base, --#if BUILDFLAG(USE_SYSTEM_FFMPEG) -- frame->pkt_duration + std::min(static_cast(0), frame->pts)); --#else - frame->duration + std::min(static_cast(0), frame->pts)); --#endif // BUILDFLAG(USE_SYSTEM_FFMPEG) - const base::TimeDelta frame_duration = - base::Seconds(frames_read / static_cast(sample_rate_)); - -diff --git a/src/3rdparty/chromium/media/filters/audio_file_reader_unittest.cc b/src/3rdparty/chromium/media/filters/audio_file_reader_unittest.cc -index a1c633d..5784fe1 100644 ---- a/src/3rdparty/chromium/media/filters/audio_file_reader_unittest.cc -+++ b/src/3rdparty/chromium/media/filters/audio_file_reader_unittest.cc -@@ -61,15 +61,14 @@ class AudioFileReaderTest : public testing::Test { - // Verify packets are consistent across demuxer runs. Reads the first few - // packets and then seeks back to the start timestamp and verifies that the - // hashes match on the packets just read. -- void VerifyPackets() { -- const int kReads = 3; -+ void VerifyPackets(int packet_reads) { - const int kTestPasses = 2; - - AVPacket packet; - base::TimeDelta start_timestamp; - std::vector packet_md5_hashes_; - for (int i = 0; i < kTestPasses; ++i) { -- for (int j = 0; j < kReads; ++j) { -+ for (int j = 0; j < packet_reads; ++j) { - ASSERT_TRUE(reader_->ReadPacketForTesting(&packet)); - - // On the first pass save the MD5 hash of each packet, on subsequent -@@ -98,7 +97,8 @@ class AudioFileReaderTest : public testing::Test { - int sample_rate, - base::TimeDelta duration, - int frames, -- int expected_frames) { -+ int expected_frames, -+ int packet_reads = 3) { - Initialize(fn); - ASSERT_TRUE(reader_->Open()); - EXPECT_EQ(channels, reader_->channels()); -@@ -112,7 +112,7 @@ class AudioFileReaderTest : public testing::Test { - EXPECT_EQ(reader_->HasKnownDuration(), false); - } - if (!packet_verification_disabled_) -- ASSERT_NO_FATAL_FAILURE(VerifyPackets()); -+ ASSERT_NO_FATAL_FAILURE(VerifyPackets(packet_reads)); - ReadAndVerify(hash, expected_frames); - } - -@@ -219,7 +219,7 @@ TEST_F(AudioFileReaderTest, AAC_ADTS) { - } - - TEST_F(AudioFileReaderTest, MidStreamConfigChangesFail) { -- RunTestFailingDecode("midstream_config_change.mp3", 42624); -+ RunTestFailingDecode("midstream_config_change.mp3", 0); - } - #endif - -@@ -229,7 +229,7 @@ TEST_F(AudioFileReaderTest, VorbisInvalidChannelLayout) { - - TEST_F(AudioFileReaderTest, WaveValidFourChannelLayout) { - RunTest("4ch.wav", "131.71,38.02,130.31,44.89,135.98,42.52,", 4, 44100, -- base::Microseconds(100001), 4411, 4410); -+ base::Microseconds(100001), 4411, 4410, /*packet_reads=*/2); - } - - TEST_F(AudioFileReaderTest, ReadPartialMP3) { -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc b/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc -index e62b2af..ab39796 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.cc -@@ -125,7 +125,7 @@ bool FFmpegVideoDecoder::IsCodecSupported(VideoCodec codec) { - } - - FFmpegVideoDecoder::FFmpegVideoDecoder(MediaLog* media_log) -- : media_log_(media_log) { -+ : media_log_(media_log), timestamp_map_(128) { - DVLOG(1) << __func__; - DETACH_FROM_SEQUENCE(sequence_checker_); - } -@@ -204,10 +204,6 @@ int FFmpegVideoDecoder::GetVideoBuffer(struct AVCodecContext* codec_context, - frame->linesize[plane] = layout->planes()[plane].stride; - } - -- // This seems unsafe, given threaded decoding. However, `reordered_opaque` is -- // also going away upstream, so we need a whole new mechanism either way. -- frame->reordered_opaque = codec_context->reordered_opaque; -- - // This will be freed by `ReleaseVideoBufferImpl`. - auto* opaque = new OpaqueData(fb_priv, frame_pool_, data, allocation_size, - std::move(*layout)); -@@ -354,8 +350,10 @@ bool FFmpegVideoDecoder::FFmpegDecode(const DecoderBuffer& buffer) { - DCHECK(packet->data); - DCHECK_GT(packet->size, 0); - -- // Let FFmpeg handle presentation timestamp reordering. -- codec_context_->reordered_opaque = buffer.timestamp().InMicroseconds(); -+ const int64_t timestamp = buffer.timestamp().InMicroseconds(); -+ const TimestampId timestamp_id = timestamp_id_generator_.GenerateNextId(); -+ timestamp_map_.Put(std::make_pair(timestamp_id, timestamp)); -+ packet->opaque = reinterpret_cast(timestamp_id.GetUnsafeValue()); - } - FFmpegDecodingLoop::DecodeStatus decode_status = decoding_loop_->DecodePacket( - packet, base::BindRepeating(&FFmpegVideoDecoder::OnNewFrame, -@@ -414,7 +412,12 @@ bool FFmpegVideoDecoder::OnNewFrame(AVFrame* frame) { - } - gfx::Size natural_size = aspect_ratio.GetNaturalSize(visible_rect); - -- const auto pts = base::Microseconds(frame->reordered_opaque); -+ const auto ts_id = TimestampId(reinterpret_cast(frame->opaque)); -+ const auto ts_lookup = timestamp_map_.Get(ts_id); -+ if (ts_lookup == timestamp_map_.end()) { -+ return false; -+ } -+ const auto pts = base::Microseconds(std::get<1>(*ts_lookup)); - auto video_frame = VideoFrame::WrapExternalDataWithLayout( - opaque->layout, visible_rect, natural_size, opaque->data, opaque->size, - pts); -@@ -489,8 +492,10 @@ bool FFmpegVideoDecoder::ConfigureDecoder(const VideoDecoderConfig& config, - codec_context_->thread_count = GetFFmpegVideoDecoderThreadCount(config); - codec_context_->thread_type = - FF_THREAD_SLICE | (low_delay ? 0 : FF_THREAD_FRAME); -+ - codec_context_->opaque = this; - codec_context_->get_buffer2 = GetVideoBufferImpl; -+ codec_context_->flags |= AV_CODEC_FLAG_COPY_OPAQUE; - - if (decode_nalus_) - codec_context_->flags2 |= AV_CODEC_FLAG2_CHUNKS; -diff --git a/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.h b/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.h -index 60cb9d5..4fa8628 100644 ---- a/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.h -+++ b/src/3rdparty/chromium/media/filters/ffmpeg_video_decoder.h -@@ -7,10 +7,12 @@ - - #include - -+#include "base/containers/lru_cache.h" - #include "base/functional/callback.h" - #include "base/memory/raw_ptr.h" - #include "base/memory/scoped_refptr.h" - #include "base/sequence_checker.h" -+#include "base/types/id_type.h" - #include "media/base/supported_video_decoder_config.h" - #include "media/base/video_decoder.h" - #include "media/base/video_decoder_config.h" -@@ -87,6 +89,20 @@ class MEDIA_EXPORT FFmpegVideoDecoder : public VideoDecoder { - // FFmpeg structures owned by this object. - std::unique_ptr codec_context_; - -+ // The gist here is that timestamps need to be 64 bits to store microsecond -+ // precision. A 32 bit integer would overflow at ~35 minutes at this level of -+ // precision. We can't cast the timestamp to the void ptr object used by the -+ // opaque field in ffmpeg then, because it would lose data on a 32 bit build. -+ // However, we don't actually have 2^31 timestamped frames in a single -+ // playback, so it's fine to use the 32 bit value as a key in a map which -+ // contains the actual timestamps. Additionally, we've in the past set 128 -+ // outstanding frames for re-ordering as a limit for cross-thread decoding -+ // tasks, so we'll do that here too with the LRU cache. -+ using TimestampId = base::IdType; -+ -+ TimestampId::Generator timestamp_id_generator_; -+ base::LRUCache timestamp_map_; -+ - VideoDecoderConfig config_; - - scoped_refptr frame_pool_; -diff --git a/src/3rdparty/chromium/third_party/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc b/src/3rdparty/chromium/third_party/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc -index f67718c..fe42aef 100644 ---- a/src/3rdparty/chromium/third_party/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc -+++ b/src/3rdparty/chromium/third_party/webrtc/modules/video_coding/codecs/h264/h264_decoder_impl.cc -@@ -229,7 +229,6 @@ int H264DecoderImpl::AVGetBuffer2(AVCodecContext* context, - int total_size = y_size + 2 * uv_size; - - av_frame->format = context->pix_fmt; -- av_frame->reordered_opaque = context->reordered_opaque; - - // Create a VideoFrame object, to keep a reference to the buffer. - // TODO(nisse): The VideoFrame's timestamp and rotation info is not used. -@@ -377,8 +376,6 @@ int32_t H264DecoderImpl::Decode(const EncodedImage& input_image, - return WEBRTC_VIDEO_CODEC_ERROR; - } - packet->size = static_cast(input_image.size()); -- int64_t frame_timestamp_us = input_image.ntp_time_ms_ * 1000; // ms -> μs -- av_context_->reordered_opaque = frame_timestamp_us; - - int result = avcodec_send_packet(av_context_.get(), packet.get()); - -@@ -395,10 +392,6 @@ int32_t H264DecoderImpl::Decode(const EncodedImage& input_image, - return WEBRTC_VIDEO_CODEC_ERROR; - } - -- // We don't expect reordering. Decoded frame timestamp should match -- // the input one. -- RTC_DCHECK_EQ(av_frame_->reordered_opaque, frame_timestamp_us); -- - // TODO(sakal): Maybe it is possible to get QP directly from FFmpeg. - h264_bitstream_parser_.ParseBitstream(input_image); - absl::optional qp = h264_bitstream_parser_.GetLastSliceQp(); diff --git a/qtwebengine-fix-quick-popup-window-positioning-under-x11.patch b/qtwebengine-fix-quick-popup-window-positioning-under-x11.patch new file mode 100644 index 0000000..318a852 --- /dev/null +++ b/qtwebengine-fix-quick-popup-window-positioning-under-x11.patch @@ -0,0 +1,45 @@ +From 65ea28e7204eaeb39588a33cfc2f69c48951aa6a Mon Sep 17 00:00:00 2001 +From: Peter Varga +Date: Thu, 14 Aug 2025 16:17:41 +0200 +Subject: [PATCH] Fix Quick popup window positioning under X11 + +If the popup window has the Qt::Dialog flag, some window managers may +try to resize and move the popup after it becomes visible. This can lead +to a blinking popup or even worse, it can cause a loop that continuously +moves the popup window. + +Replace Qt::Tool flag with Qt::Popup to get rid of the Qt::Dialog flag +but keep popup as popup. + +Note on Wayland Qt:Tool is xdg toplevel not a 'popup' neither 'grabbing +popup' and it creates shell surface. This means it will get random +position on the screen. + +Note this tricky issue as we already changed that several times both +for widgets and quick due to different reasons (see 1390979a, 2f720836, +58467ed19, 7e7dd2625, c56169f7a1) + +Fixes: QTBUG-140321 +Task-number: QTBUG-132794 +Task-number: QTBUG-138747 +Pick-to: 6.10 +Change-Id: I8c3a94519008455fac2d8ab4c3bf34d860e2475b +Reviewed-by: Peter Varga +--- + .../render_widget_host_view_qt_delegate_quickwindow.cpp | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/webenginequick/render_widget_host_view_qt_delegate_quickwindow.cpp b/src/webenginequick/render_widget_host_view_qt_delegate_quickwindow.cpp +index 3ad88ca39aa..95b5e3500b3 100644 +--- a/src/webenginequick/render_widget_host_view_qt_delegate_quickwindow.cpp ++++ b/src/webenginequick/render_widget_host_view_qt_delegate_quickwindow.cpp +@@ -31,7 +31,8 @@ RenderWidgetHostViewQtDelegateQuickWindow::RenderWidgetHostViewQtDelegateQuickWi + RenderWidgetHostViewQtDelegateItem *realDelegate, QWindow *parent) + : QQuickWindow(), m_realDelegate(realDelegate), m_virtualParent(nullptr), m_transformed(false) + { +- setFlags(Qt::Tool | Qt::WindowStaysOnTopHint | Qt::FramelessWindowHint | Qt::WindowDoesNotAcceptFocus); ++ setFlags(Qt::Popup | Qt::WindowStaysOnTopHint | Qt::FramelessWindowHint ++ | Qt::WindowDoesNotAcceptFocus); + realDelegate->setParentItem(contentItem()); + setTransientParent(parent); + } diff --git a/qtwebengine-move-gpu-info-logging-to-gpu-thread.patch b/qtwebengine-move-gpu-info-logging-to-gpu-thread.patch new file mode 100644 index 0000000..3d64eff --- /dev/null +++ b/qtwebengine-move-gpu-info-logging-to-gpu-thread.patch @@ -0,0 +1,607 @@ +From 1534a75e57b47d763af8f32eec91bc8471442816 Mon Sep 17 00:00:00 2001 +From: Peter Varga +Date: Mon, 20 Oct 2025 10:43:49 +0200 +Subject: [PATCH] Move GPU info logging to the GPU thread + +Accessing certain GPU information (eg. GPU feature status values) from +the browser thread requires extra API on top of Chromium, such as +content::GpuChildThread::gpu_channel_manager(). + +This change moves the logging to the GPU thread, allowing use of +existing APIs like content::GpuDataManager::GetFeatureStatus(). + +Task-number: QTBUG-139335 +Fixes: QTBUG-142497 +Fixes: QTBUG-142720 +Change-Id: I4e4471a78258a1502ec0e11683cae3936e170ce1 +Reviewed-by: Moss Heim +(cherry picked from commit 0b65b0754d1534280acc3fe48be61127ce24ac93) +--- + +diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt +index 64ef09f..eb83a82 100644 +--- a/src/core/CMakeLists.txt ++++ b/src/core/CMakeLists.txt +@@ -132,6 +132,7 @@ + file_system_access/file_system_access_permission_request_manager_qt.cpp file_system_access/file_system_access_permission_request_manager_qt.h + find_text_helper.cpp find_text_helper.h + global_descriptors_qt.h ++ gpu/content_gpu_client_qt.cpp gpu/content_gpu_client_qt.h + javascript_dialog_controller.cpp javascript_dialog_controller.h javascript_dialog_controller_p.h + javascript_dialog_manager_qt.cpp javascript_dialog_manager_qt.h + login_delegate_qt.cpp login_delegate_qt.h +diff --git a/src/core/content_client_qt.cpp b/src/core/content_client_qt.cpp +index 4d81e39..ed63980 100644 +--- a/src/core/content_client_qt.cpp ++++ b/src/core/content_client_qt.cpp +@@ -4,8 +4,6 @@ + + #include "content_client_qt.h" + +-#include "compositor/compositor.h" +- + #include "base/command_line.h" + #include "base/files/file_util.h" + #include "base/json/json_string_value_serializer.h" +@@ -13,15 +11,11 @@ + #include "base/strings/string_util.h" + #include "base/values.h" + #include "base/version.h" +-#include "content/gpu/gpu_child_thread.h" + #include "content/public/common/cdm_info.h" + #include "content/public/common/content_constants.h" + #include "content/public/common/content_switches.h" + #include "extensions/buildflags/buildflags.h" + #include "extensions/common/constants.h" +-#include "gpu/config/gpu_feature_info.h" +-#include "gpu/config/gpu_preferences.h" +-#include "gpu/ipc/service/gpu_channel_manager.h" + #include "media/base/media_switches.h" + #include "media/base/video_codecs.h" + #include "media/cdm/supported_audio_codecs.h" +@@ -34,10 +28,8 @@ + #include + #include + #include +-#include + #include + #include +-#include + + #if BUILDFLAG(IS_WIN) + #include "ui/gl/gl_utils.h" +@@ -497,165 +489,4 @@ + return origin_trial_policy_.get(); + } + +-void ContentClientQt::SetGpuInfo(const gpu::GPUInfo &gpu_info) +-{ +- base::CommandLine *commandLine = base::CommandLine::ForCurrentProcess(); +- const bool isBrowserProcess = !commandLine->HasSwitch(switches::kProcessType); +- const bool isMainThread = QThread::currentThread() == qApp->thread(); +- +- // Limit this to the main thread of the browser process for now. +- if (!isBrowserProcess || !isMainThread) +- return; +- +- if (!gpu_info.IsInitialized()) { +- // This is probably not an issue but suspicious. +- qWarning("Failed to initialize GPUInfo."); +- return; +- } +- +- const gpu::GPUInfo::GPUDevice &primary = gpu_info.gpu; +- +- // Do not print the info again if the device hasn't been changed. +- // Change of the device is unexpected: we don't support or implement fallback yet. +- // It is suspicious if the info is logged twice. +- if (m_gpuInfo && m_gpuInfo->gpu.device_string == primary.device_string) +- return; +- m_gpuInfo = gpu_info; +- +- auto *gpuChannelManager = content::GpuChildThread::instance()->gpu_channel_manager(); +- const gpu::GpuFeatureStatus gpuCompositingStatus = +- gpuChannelManager->gpu_feature_info() +- .status_values[gpu::GPU_FEATURE_TYPE_ACCELERATED_GL]; +- +-#if BUILDFLAG(IS_OZONE) +- if (gpuCompositingStatus == gpu::kGpuFeatureStatusEnabled) { +- // See entry 3 in //gpu/config/software_rendering_list.json +- QRegularExpression filter(u"software|llvmpipe|softpipe"_s, +- QRegularExpression::CaseInsensitiveOption); +- if (filter.match(QLatin1StringView(gpu_info.gl_renderer)).hasMatch()) { +- qWarning("Hardware rendering is enabled but it is not supported with Mesa software " +- "rasterizer. Expect troubles."); +- +- if (gpuChannelManager->gpu_preferences().ignore_gpu_blocklist) +- qWarning("Rendering may fail because --ignore-gpu-blocklist is set."); +- } +- } +-#endif +- +- if (Q_LIKELY(!lcWebEngineCompositor().isDebugEnabled())) +- return; +- +- auto deviceToString = [](const gpu::GPUInfo::GPUDevice &device) -> QString { +- if (device.vendor_id == 0x0) +- return "Disabled"_L1; +- +- QString log; +- +- // TODO: Factor vendor translation out from QtWebEngineCore::GPUInfo. +- // Only name the most common desktop GPU hardware vendors for now. +- switch (device.vendor_id) { +- case 0x1002: +- log += "AMD"_L1; +- break; +- case 0x10DE: +- log += "Nvidia"_L1; +- break; +- case 0x8086: +- log += "Intel"_L1; +- break; +- default: +- log += "vendor id: 0x"_L1 + QString::number(device.vendor_id, 16); +- } +- +- log += ", device id: 0x"_L1 + QString::number(device.device_id, 16); +- +- if (!device.driver_vendor.empty()) { +- log += ", driver: "_L1 + QLatin1StringView(device.driver_vendor) + u' ' +- + QLatin1StringView(device.driver_version); +- } +- log += ", system device id: 0x"_L1 + QString::number(device.system_device_id, 16); +- +- log += ", preference: "_L1; +- switch (device.gpu_preference) { +- case gl::GpuPreference::kNone: +- log += "None"_L1; +- break; +- case gl::GpuPreference::kDefault: +- log += "Default"_L1; +- break; +- case gl::GpuPreference::kLowPower: +- log += "LowPower"_L1; +- break; +- case gl::GpuPreference::kHighPerformance: +- log += "HighPerformance"_L1; +- break; +- } +- +- log += ", active: "_L1 + (device.active ? "yes"_L1 : "no"_L1); +- return log; +- }; +- +- QString log; +- +- log = "GPU Compositing: "; +- switch (gpuCompositingStatus) { +- case gpu::kGpuFeatureStatusEnabled: +- log += "Enabled"_L1; +- break; +- case gpu::kGpuFeatureStatusBlocklisted: +- log += "Blocklisted"_L1; +- break; +- case gpu::kGpuFeatureStatusDisabled: +- log += "Disabled"_L1; +- break; +- case gpu::kGpuFeatureStatusSoftware: +- log += "Software"_L1; +- break; +- case gpu::kGpuFeatureStatusUndefined: +- log += "Undefined"_L1; +- break; +- case gpu::kGpuFeatureStatusMax: +- log += "Max"_L1; +- break; +- } +- qCDebug(lcWebEngineCompositor, "%ls", qUtf16Printable(log)); +- +- if (gpu_info.gl_vendor.empty() || gpu_info.gl_vendor == "Disabled") { +- log = "ANGLE is disabled:\n"_L1; +- log += " GL Renderer: "_L1 + QLatin1StringView(gpu_info.gl_renderer) + u'\n'; +- log += " Software Renderer: "_L1 + (primary.IsSoftwareRenderer() ? "yes"_L1 : "no"_L1) +- + u'\n'; +- log += " Primary GPU: "_L1 + deviceToString(primary) + u'\n'; +- } else { +- log = QLatin1StringView(gpu_info.display_type) + " display is initialized:\n"_L1; +- log += " GL Renderer: "_L1 + QLatin1StringView(gpu_info.gl_renderer) + u'\n'; +- log += " "_L1 + QString::number(gpu_info.GpuCount()) + " GPU(s) detected:\n"_L1; +- log += " "_L1 + deviceToString(primary) + u'\n'; +- for (auto &secondary : gpu_info.secondary_gpus) +- log += " "_L1 + deviceToString(secondary) + u'\n'; +- +- log += " NVIDIA Optimus: "_L1 + (gpu_info.optimus ? "enabled"_L1 : "disabled"_L1) + u'\n'; +- log += " AMD Switchable: "_L1 + (gpu_info.amd_switchable ? "enabled"_L1 : "disabled"_L1); +- } +- +- qCDebug(lcWebEngineCompositor, "%ls", qUtf16Printable(log)); +- +-#if BUILDFLAG(IS_WIN) +- log = "Windows specific driver information:\n"_L1; +- +- log += " Direct Composition: "_L1; +- if (gpu_info.overlay_info.direct_composition) +- log += "enabled\n"_L1; +- else if (gl::GetGlWorkarounds().disable_direct_composition) +- log += "disabled by workaround\n"_L1; +- else +- log += "disabled\n"_L1; +- +- log += " Supports Overlays: "_L1 +- + (gpu_info.overlay_info.supports_overlays ? "yes"_L1 : "no"_L1) + u'\n'; +- log += " Supports D3D Shared Images: "_L1 + (gpu_info.shared_image_d3d ? "yes"_L1 : "no"_L1); +- qCDebug(lcWebEngineCompositor, "%ls", qUtf16Printable(log)); +-#endif +-} +- + } // namespace QtWebEngineCore +diff --git a/src/core/content_client_qt.h b/src/core/content_client_qt.h +index 2936c23..d5f9e71 100644 +--- a/src/core/content_client_qt.h ++++ b/src/core/content_client_qt.h +@@ -10,11 +10,9 @@ + #include "base/synchronization/lock.h" + #include "components/embedder_support/origin_trials/origin_trial_policy_impl.h" + #include "content/public/common/content_client.h" +-#include "gpu/config/gpu_info.h" + #include "ui/base/layout.h" + + #include +-#include + + namespace QtWebEngineCore { + +@@ -32,13 +30,11 @@ + gfx::Image &GetNativeImageNamed(int resource_id) override; + std::u16string GetLocalizedString(int message_id) override; + blink::OriginTrialPolicy *GetOriginTrialPolicy() override; +- void SetGpuInfo(const gpu::GPUInfo &gpu_info) override; + + private: + // Used to lock when |origin_trial_policy_| is initialized. + base::Lock origin_trial_policy_lock_; + std::unique_ptr origin_trial_policy_; +- std::optional m_gpuInfo; + }; + + } // namespace QtWebEngineCore +diff --git a/src/core/content_main_delegate_qt.cpp b/src/core/content_main_delegate_qt.cpp +index 6c61c7a..1512f9a 100644 +--- a/src/core/content_main_delegate_qt.cpp ++++ b/src/core/content_main_delegate_qt.cpp +@@ -194,6 +194,12 @@ + return m_browserClient.get(); + } + ++content::ContentGpuClient *ContentMainDelegateQt::CreateContentGpuClient() ++{ ++ m_gpuClient.reset(new ContentGpuClientQt); ++ return m_gpuClient.get(); ++} ++ + content::ContentRendererClient *ContentMainDelegateQt::CreateContentRendererClient() + { + #if BUILDFLAG(IS_LINUX) +diff --git a/src/core/content_main_delegate_qt.h b/src/core/content_main_delegate_qt.h +index cb320ec..b725d88 100644 +--- a/src/core/content_main_delegate_qt.h ++++ b/src/core/content_main_delegate_qt.h +@@ -10,6 +10,7 @@ + #include "content_browser_client_qt.h" + #include "content_client_qt.h" + #include "content_utility_client_qt.h" ++#include "gpu/content_gpu_client_qt.h" + + namespace QtWebEngineCore { + +@@ -23,6 +24,7 @@ + + content::ContentClient *CreateContentClient() override; + content::ContentBrowserClient* CreateContentBrowserClient() override; ++ content::ContentGpuClient* CreateContentGpuClient() override; + content::ContentRendererClient* CreateContentRendererClient() override; + content::ContentUtilityClient* CreateContentUtilityClient() override; + std::optional BasicStartupComplete() override; +@@ -30,6 +32,7 @@ + private: + ContentClientQt m_contentClient; + std::unique_ptr m_browserClient; ++ std::unique_ptr m_gpuClient; + std::unique_ptr m_utilityClient; + }; + +diff --git a/src/core/gpu/content_gpu_client_qt.cpp b/src/core/gpu/content_gpu_client_qt.cpp +new file mode 100644 +index 0000000..2cb6592 +--- /dev/null ++++ b/src/core/gpu/content_gpu_client_qt.cpp +@@ -0,0 +1,236 @@ ++// Copyright (C) 2025 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++// Qt-Security score:significant reason:default ++ ++#include "content_gpu_client_qt.h" ++ ++#include "compositor/compositor.h" ++ ++#include "content/public/browser/browser_thread.h" ++#include "content/public/browser/gpu_data_manager.h" ++#include "content/public/browser/gpu_data_manager_observer.h" ++#include "gpu/config/gpu_driver_bug_workarounds.h" ++#include "gpu/config/gpu_info.h" ++#include "mojo/public/cpp/bindings/binder_map.h" ++ ++#include ++#include ++ ++#include ++#include ++ ++#if BUILDFLAG(IS_WIN) ++#include "ui/gl/gl_utils.h" ++#endif ++ ++using namespace Qt::StringLiterals; ++ ++namespace QtWebEngineCore { ++ ++namespace { ++static inline bool isSameDevice(const gpu::GPUInfo::GPUDevice &d1, ++ const gpu::GPUInfo::GPUDevice &d2) ++{ ++ return std::tie(d1.vendor_id, d1.device_id, d1.system_device_id, d1.vendor_string, ++ d1.device_string, d1.driver_vendor, d1.driver_version) ++ == std::tie(d2.vendor_id, d2.device_id, d2.system_device_id, d2.vendor_string, ++ d2.device_string, d2.driver_vendor, d2.driver_version); ++} ++ ++static QString gpuDeviceToString(const gpu::GPUInfo::GPUDevice &device) ++{ ++ if (device.vendor_id == 0x0) ++ return "Disabled"_L1; ++ ++ QString deviceString; ++ ++ // TODO: Factor vendor translation out from QtWebEngineCore::GPUInfo. ++ // Only name the most common desktop GPU hardware vendors for now. ++ switch (device.vendor_id) { ++ case 0x1002: ++ deviceString += "AMD"_L1; ++ break; ++ case 0x10DE: ++ deviceString += "Nvidia"_L1; ++ break; ++ case 0x8086: ++ deviceString += "Intel"_L1; ++ break; ++ default: ++ deviceString += "vendor id: 0x"_L1 + QString::number(device.vendor_id, 16); ++ } ++ ++ deviceString += ", device id: 0x"_L1 + QString::number(device.device_id, 16); ++ ++ if (!device.driver_vendor.empty()) { ++ deviceString += ", driver: "_L1 + QLatin1StringView(device.driver_vendor) + u' ' ++ + QLatin1StringView(device.driver_version); ++ } ++ deviceString += ", system device id: 0x"_L1 + QString::number(device.system_device_id, 16); ++ ++ deviceString += ", preference: "_L1; ++ switch (device.gpu_preference) { ++ case gl::GpuPreference::kNone: ++ deviceString += "None"_L1; ++ break; ++ case gl::GpuPreference::kDefault: ++ deviceString += "Default"_L1; ++ break; ++ case gl::GpuPreference::kLowPower: ++ deviceString += "LowPower"_L1; ++ break; ++ case gl::GpuPreference::kHighPerformance: ++ deviceString += "HighPerformance"_L1; ++ break; ++ } ++ ++ deviceString += ", active: "_L1 + (device.active ? "yes"_L1 : "no"_L1); ++ return deviceString; ++} ++ ++static inline const char *gpuFeatureStatusToString(const gpu::GpuFeatureStatus &status) ++{ ++ switch (status) { ++ case gpu::kGpuFeatureStatusEnabled: ++ return "Enabled"; ++ case gpu::kGpuFeatureStatusBlocklisted: ++ return "Blocklisted"; ++ case gpu::kGpuFeatureStatusDisabled: ++ return "Disabled"; ++ case gpu::kGpuFeatureStatusSoftware: ++ return "Software"; ++ case gpu::kGpuFeatureStatusUndefined: ++ return "Undefined"; ++ case gpu::kGpuFeatureStatusMax: ++ return "Max"; ++ } ++} ++ ++static QString angleInfo(const gpu::GPUInfo &gpuInfo) ++{ ++ QString info; ++ ++ if (gpuInfo.gl_vendor.empty() || gpuInfo.gl_vendor == "Disabled") { ++ info = "ANGLE is disabled:\n"_L1; ++ info += " GL Renderer: "_L1 + QLatin1StringView(gpuInfo.gl_renderer) + u'\n'; ++ info += " Software Renderer: "_L1 + (gpuInfo.gpu.IsSoftwareRenderer() ? "yes"_L1 : "no"_L1) ++ + u'\n'; ++ info += " Primary GPU: "_L1 + gpuDeviceToString(gpuInfo.gpu) + u'\n'; ++ return info; ++ } ++ ++ info = QLatin1StringView(gpuInfo.display_type) + " display is initialized:\n"_L1; ++ info += " GL Renderer: "_L1 + QLatin1StringView(gpuInfo.gl_renderer) + u'\n'; ++ info += " "_L1 + QString::number(gpuInfo.GpuCount()) + " GPU(s) detected:\n"_L1; ++ info += " "_L1 + gpuDeviceToString(gpuInfo.gpu) + u'\n'; ++ for (auto &secondary : gpuInfo.secondary_gpus) ++ info += " "_L1 + gpuDeviceToString(secondary) + u'\n'; ++ ++ info += " NVIDIA Optimus: "_L1 + (gpuInfo.optimus ? "enabled"_L1 : "disabled"_L1) + u'\n'; ++ info += " AMD Switchable: "_L1 + (gpuInfo.amd_switchable ? "enabled"_L1 : "disabled"_L1); ++ ++ return info; ++} ++ ++#if BUILDFLAG(IS_WIN) ++static QString windowsInfo(const gpu::GPUInfo &gpuInfo) ++{ ++ QString info; ++ info = "Windows specific driver information:\n"_L1; ++ ++ info += " Direct Composition: "_L1; ++ if (gpuInfo.overlay_info.direct_composition) ++ info += "enabled\n"_L1; ++ else if (gl::GetGlWorkarounds().disable_direct_composition) ++ info += "disabled by workaround\n"_L1; ++ else ++ info += "disabled\n"_L1; ++ ++ info += " Supports Overlays: "_L1 ++ + (gpuInfo.overlay_info.supports_overlays ? "yes"_L1 : "no"_L1) + u'\n'; ++ info += " Supports D3D Shared Images: "_L1 + (gpuInfo.shared_image_d3d ? "yes"_L1 : "no"_L1); ++ return info; ++} ++#endif ++} // namespace ++ ++class GpuObserver : public content::GpuDataManagerObserver ++{ ++public: ++ GpuObserver(ContentGpuClientQt *client) : m_client(client) ++ { ++ content::GpuDataManager *manager = content::GpuDataManager::GetInstance(); ++ if (manager->IsEssentialGpuInfoAvailable()) ++ OnGpuInfoUpdate(); ++ } ++ ++ ~GpuObserver() { content::GpuDataManager::GetInstance()->RemoveObserver(this); } ++ ++ void OnGpuInfoUpdate() override ++ { ++ content::GpuDataManager *manager = content::GpuDataManager::GetInstance(); ++ Q_ASSERT(manager->IsEssentialGpuInfoAvailable()); ++ ++ const gpu::GPUInfo &gpuInfo = manager->GetGPUInfo(); ++ Q_ASSERT(gpuInfo.IsInitialized()); ++ ++ // Avoid logging the info again if the device hasn't changed. ++ // A change in the device is unexpected, as we currently don't support or implement ++ // fallback. Logging the info multiple times may indicate a problem. ++ if (m_gpuInfo && isSameDevice(m_gpuInfo->gpu, gpuInfo.gpu)) ++ return; ++ m_gpuInfo = gpuInfo; ++ ++ const gpu::GpuFeatureStatus gpuCompositingStatus = ++ manager->GetFeatureStatus(gpu::GPU_FEATURE_TYPE_ACCELERATED_GL); ++ qCDebug(lcWebEngineCompositor, "GPU Compositing: %s", ++ gpuFeatureStatusToString(gpuCompositingStatus)); ++ ++#if BUILDFLAG(IS_OZONE) ++ if (gpuCompositingStatus == gpu::kGpuFeatureStatusEnabled) { ++ // See entry 3 in //gpu/config/software_rendering_list.json ++ QRegularExpression filter(u"software|llvmpipe|softpipe"_s, ++ QRegularExpression::CaseInsensitiveOption); ++ if (filter.match(QLatin1StringView(gpuInfo.gl_renderer)).hasMatch()) { ++ qWarning("Hardware rendering is enabled but it is not supported with Mesa software " ++ "rasterizer. Expect troubles."); ++ ++ if (m_client->gpuPreferences().ignore_gpu_blocklist) ++ qWarning("Rendering may fail because --ignore-gpu-blocklist is set."); ++ } ++ } ++#endif ++ ++ qCDebug(lcWebEngineCompositor, "%ls", qUtf16Printable(angleInfo(gpuInfo))); ++#if BUILDFLAG(IS_WIN) ++ qCDebug(lcWebEngineCompositor, "%ls", qUtf16Printable(windowsInfo(gpuInfo))); ++#endif ++ } ++ ++private: ++ ContentGpuClientQt *m_client; ++ std::optional m_gpuInfo; ++}; ++ ++ContentGpuClientQt::ContentGpuClientQt() = default; ++ContentGpuClientQt::~ContentGpuClientQt() = default; ++ ++void ContentGpuClientQt::GpuServiceInitialized() ++{ ++ // This is expected to be called on the GPU thread. ++ Q_ASSERT(!content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); ++ ++ m_gpuObserver.reset(new GpuObserver(this)); ++ content::GpuDataManager::GetInstance()->AddObserver(m_gpuObserver.get()); ++} ++ ++void ContentGpuClientQt::ExposeInterfacesToBrowser( ++ const gpu::GpuPreferences &gpu_preferences, ++ const gpu::GpuDriverBugWorkarounds &gpu_workarounds, mojo::BinderMap *binders) ++{ ++ Q_UNUSED(gpu_workarounds); ++ Q_UNUSED(binders); ++ m_gpuPreferences = gpu_preferences; ++} ++ ++} // namespace QtWebEngineCore +diff --git a/src/core/gpu/content_gpu_client_qt.h b/src/core/gpu/content_gpu_client_qt.h +new file mode 100644 +index 0000000..51b3a0d +--- /dev/null ++++ b/src/core/gpu/content_gpu_client_qt.h +@@ -0,0 +1,46 @@ ++// Copyright (C) 2025 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++// Qt-Security score:significant reason:default ++ ++#ifndef CONTENT_GPU_CLIENT_QT_H ++#define CONTENT_GPU_CLIENT_QT_H ++ ++#include "content/public/gpu/content_gpu_client.h" ++#include "gpu/config/gpu_preferences.h" ++ ++#include ++ ++namespace gpu { ++class GpuDriverBugWorkarounds; ++} ++ ++namespace mojo { ++class BinderMap; ++} ++ ++namespace QtWebEngineCore { ++ ++class GpuObserver; ++ ++class ContentGpuClientQt : public content::ContentGpuClient ++{ ++public: ++ ContentGpuClientQt(); ++ ~ContentGpuClientQt(); ++ ++ gpu::GpuPreferences gpuPreferences() const { return m_gpuPreferences; } ++ ++ // Overridden from content::ContentGpuClient: ++ void GpuServiceInitialized() override; ++ void ExposeInterfacesToBrowser(const gpu::GpuPreferences &gpu_preferences, ++ const gpu::GpuDriverBugWorkarounds &gpu_workarounds, ++ mojo::BinderMap *binders) override; ++ ++private: ++ QScopedPointer m_gpuObserver; ++ gpu::GpuPreferences m_gpuPreferences; ++}; ++ ++} // namespace QtWebEngineCore ++ ++#endif // CONTENT_GPU_CLIENT_QT_H diff --git a/qtwebengine-use-openh264.patch b/qtwebengine-use-openh264.patch index cdf68f4..c3541e2 100644 --- a/qtwebengine-use-openh264.patch +++ b/qtwebengine-use-openh264.patch @@ -1,9 +1,9 @@ diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt -index de5222645..eb27e8b4e 100644 +index cc992b4..7b6326f 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt -@@ -448,6 +448,8 @@ foreach(arch ${archs}) - use_udev=true +@@ -449,6 +449,8 @@ foreach(arch ${archs}) + use_bluez=false is_cfi=false use_ozone=true + media_use_openh264=true diff --git a/series.ppc64 b/series.ppc64 index dc1fa95..c0e8461 100644 --- a/series.ppc64 +++ b/series.ppc64 @@ -1,4 +1,4 @@ -# from chromium-122.0.6261.128 patchset on quickbuild.io +# from chromium-130 branch at https://gitlab.raptorengineering.com/raptor-engineering-public/chromium/openpower-patches.git # do following edits to the patches: # - third_party/0001-Add-PPC64-support-for-boringssl.patch # - remove third_party/boringssl/src/crypto/test/abi_test.h @@ -34,11 +34,11 @@ ppc64le/third_party/0002-third_party-lss-kernel-structs.patch ppc64le/libaom/0001-Add-ppc64-target-to-libaom.patch ppc64le/libaom/0001-Add-pregenerated-config-for-libaom-on-ppc64.patch ppc64le/third_party/0002-third_party-libvpx-Remove-bad-ppc64-config.patch -ppc64le/third_party/0002-third-party-boringssl-add-generated-files.patch +ppc64le/third_party/0002-Add-PPC64-generated-files-for-boringssl.patch ppc64le/third_party/0003-third_party-libvpx-Add-ppc64-generated-config.patch ppc64le/crashpad/0001-Implement-support-for-PPC64-on-Linux.patch ppc64le/fixes/fix-partition-alloc-compile.patch -ppc64le/third_party/0001-Fix-highway-ppc-hwcap.patch ppc64le/third_party/use-sysconf-page-size-on-ppc64.patch -ppc64le/third_party/dawn-fix-typos.patch ppc64le/third_party/dawn-fix-ppc64le-detection.patch +ppc64le/core/add-ppc64-pthread-stack-size.patch +ppc64le/third_party/0001-third-party-hwy-wrong-include.patch diff --git a/sources b/sources index b5e54a6..3d8dace 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (qtwebengine-everywhere-src-6.8.2-clean.tar.xz) = 815e632075a7c5bd8950d887f56c66eac280dc02fed976907b8c377544563d19d1bef632336c2d170fdfb55cb271c8982dae3dffce2c2c44646d212125ebb3b3 SHA512 (pulseaudio-12.2-headers.tar.gz) = a5a9bcbb16030b3bc83cc0cc8f5e7f90e0723d3e83258a5c77eacb32eaa267118a73fa7814fbcc99a24e4907916a2b371ebb6dedc4f45541c3acf6c834fd35be +SHA512 (qtwebengine-everywhere-src-6.10.1-clean.tar.xz) = c297c030623663dce4943562ca60ac64067702dd96b487f5786fb765c477162ee7d040e6ecb4b820ff9ef162259e1f56bd1054e20e0982fef90fa32857a462c9