All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
@ 2026-08-30 12:58 sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release sunilkumar.dora
                   ` (11 more replies)
  0 siblings, 12 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

This upgrades clang/llvm from 22.1.8 to 23.1.0 and fixes the fallout
found while testing the result.

The carried LLVM patch stack goes from 41 to 35: seven dropped
because 23.1.0 already contains the fix or the code they patched no
longer exists, three reworked for LLVM 23, and one added for a 32-bit
x86 build break, already merged in llvm-project.

Please apply with git am --keep-cr: patch 8 fixes an ovmf file that
uses CRLF line endings, and plain git am corrupts the patch.

I have also reported the underlying bugs upstream:
  llvm float16 fix, merged:
    https://github.com/llvm/llvm-project/pull/219675
  ovmf fix, sent to edk2:
    https://github.com/tianocore/edk2/pull/13038
  pango warning, the root cause is in GLib, reported to both:
    https://gitlab.gnome.org/GNOME/glib/-/issues/4038
    https://gitlab.gnome.org/GNOME/pango/-/issues/900
  vulkan-samples warning, which is a real bug in their code:
    https://github.com/KhronosGroup/Vulkan-Samples/issues/1570

Tested: oe-selftest clang suites on qemuarm, qemuarm64, qemux86,
qemux86-64 and qemuriscv64 on the autobuilder, musl images on qemux86
and qemuarm64, a qemux86 world build with TOOLCHAIN=clang, 32-bit
multilib, and core-image-minimal testimage runs.

Deepesh Varatharajan (2):
  rust: Fix build and oe-selftest failures with LLVM 23
  clang/llvm: Ignore tests fail with clang/llvm 23 upgrade

Sunil Dora (9):
  clang/llvm: Upgrade to 23.1.0 release
  spirv-llvm-translator: Upgrade to 23.1.0
  openmp: Build via the LLVM runtimes entry point
  rust: Do not pass the removed x86 amx-tf32 feature to LLVM 23
  clang: Disable clangd's decision-forest completion model on powerpc
  pango: Don't turn clang 23's -Wunused-but-set-global into an error
  ovmf: Fix memcpy alias prototype for clang 23
  vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error
  gettext: Export a fully-flagged Objective-C compiler

 meta/conf/distro/include/maintainers.inc      |   2 +-
 meta/lib/oeqa/selftest/cases/clang.py         |  10 +
 meta/lib/oeqa/selftest/cases/rust.py          |   1 +
 ...t-env.in-do-not-add-C-CXX-parameters.patch |  17 +-
 meta/recipes-core/gettext/gettext_1.0.bb      |   5 +
 ...sicLib-fix-memcpy-alias-prototype-fo.patch |  35 +
 meta/recipes-core/ovmf/ovmf_git.bb            |   1 +
 ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
 ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 --
 ...-support-a-new-embedded-linux-target.patch | 309 --------
 ...env-override-of-exe-and-libdir-path.patch} |   4 +-
 ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
 ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
 ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
 ...fine-releative-gcc-installation-dir.patch} |  10 +-
 ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
 ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
 ...ure-for-packages-using-find_package.patch} |  20 +-
 ...e-dir-location-for-cross-toolchains.patch} |   4 +-
 ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
 ...clang-Use-python3-in-python-scripts.patch} |   6 +-
 ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +-
 ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
 ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
 ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
 ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 --
 ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
 ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
 ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
 ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
 ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 +-
 ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
 ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
 ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
 ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
 ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
 ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
 ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
 ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
 ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
 ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
 ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
 ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
 ...> 0034-guard-clang-tools-extra-test.patch} |  47 +-
 ...ng-block-when-searching-for-noreturn.patch |  41 --
 ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 +
 ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 --------
 ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 -
 ...te-exit-fold-candidates-in-determini.patch |  71 --
 meta/recipes-devtools/clang/clang_git.bb      |   4 +
 meta/recipes-devtools/clang/common-clang.inc  |   4 +-
 meta/recipes-devtools/clang/common.inc        |  78 +--
 meta/recipes-devtools/clang/openmp_git.bb     |   5 +-
 ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
 ...llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch |  38 +
 meta/recipes-devtools/rust/rust-source.inc    |   2 +
 ...ror-on-clang-s-unused-but-set-global.patch |  28 +
 meta/recipes-graphics/pango/pango_1.58.0.bb   |   1 +
 ...1.5.bb => spirv-llvm-translator_23.1.0.bb} |   6 +-
 .../vulkan/vulkan-samples_git.bb              |   4 +-
 60 files changed, 1109 insertions(+), 1113 deletions(-)
 create mode 100644 meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch
 rename meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
 rename meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
 rename meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
 rename meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
 rename meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
 rename meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
 rename meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
 rename meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
 rename meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
 rename meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
 rename meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
 rename meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch => 0034-guard-clang-tools-extra-test.patch} (83%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
 create mode 100644 meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
 create mode 100644 meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
 create mode 100644 meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch
 create mode 100644 meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
 rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb => spirv-llvm-translator_23.1.0.bb} (87%)

-- 
2.43.0



^ permalink raw reply	[flat|nested] 30+ messages in thread

* [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 19:53   ` Khem Raj
  2026-08-30 12:58 ` [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0 sunilkumar.dora
                   ` (10 subsequent siblings)
  11 siblings, 1 reply; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

Rebase the OE patch stack from 22.1.8 onto the 23.x release branch.

Dropped, the fix is already in 23.1.0:
  compiler-rt: do not use backtrace APIs on non-glibc linux
    https://github.com/llvm/llvm-project/commit/252ad2052409
  Rename UNUSED and UNKNOWN elements of OffloadArch enum
    https://github.com/llvm/llvm-project/commit/82f18b02d9fe
  libcxxabi: declare __gnu_unwind_frame in cxa_personality
    https://github.com/llvm/llvm-project/commit/8119f1854948
  LoopUnroll: iterate exit fold candidates in deterministic order
    https://github.com/llvm/llvm-project/commit/965f9d87adb0
  Prevent revisiting block when searching for noreturn
    https://github.com/llvm/llvm-project/commit/330b40e11fd2

Dropped, obsolete:
  libcxxabi: find libunwind headers when LIBCXXABI_LIBUNWIND_INCLUDES
    (cmake's find_path now searches the user-supplied path first)
  compiler-rt: support a new embedded linux target
    (only added files for the long-removed Makefile build system)

Reworked for the TripleName.def triple string tables added in 23:
  llvm/clang: insert anchor for adding OE distro vendor
  clang/llvm: add OE specific ABI triple for N32 ABI

Reworked for the restructured powerpc source lists in compiler-rt:
  compiler-rt: enable __int128 for ppc32

Newly carried, already merged in LLVM main:
  libc: disable float16 on 32-bit x86 without SSE2
    https://github.com/llvm/llvm-project/commit/05da143c63d3

GCC 16 defines __FLT16_MANT_DIG__ when targeting i686 without SSE2,
so the llvm-libc float16 headers that APFloat.cpp now includes fail
to build for 32-bit x86 multilib ("SSE register return with SSE2
disabled") without that last patch.

Release notes: https://releases.llvm.org/23.1.0/docs/ReleaseNotes.html

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 meta/conf/distro/include/maintainers.inc      |   2 +-
 ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
 ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 ----
 ...-support-a-new-embedded-linux-target.patch | 309 ------------------
 ...env-override-of-exe-and-libdir-path.patch} |   4 +-
 ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
 ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
 ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
 ...fine-releative-gcc-installation-dir.patch} |  10 +-
 ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
 ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
 ...ure-for-packages-using-find_package.patch} |  20 +-
 ...e-dir-location-for-cross-toolchains.patch} |   4 +-
 ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
 ...clang-Use-python3-in-python-scripts.patch} |   6 +-
 ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +--
 ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
 ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
 ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
 ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 ----
 ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
 ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
 ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
 ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
 ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 ++--
 ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
 ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
 ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
 ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
 ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
 ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
 ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
 ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
 ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
 ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
 ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
 ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
 ...> 0034-guard-clang-tools-extra-test.patch} |  47 ++-
 ...ng-block-when-searching-for-noreturn.patch |  41 ---
 ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 ++
 ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 ----------------
 ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 --
 ...te-exit-fold-candidates-in-determini.patch |  71 ----
 meta/recipes-devtools/clang/common-clang.inc  |   4 +-
 meta/recipes-devtools/clang/common.inc        |  78 ++---
 45 files changed, 302 insertions(+), 1102 deletions(-)
 rename meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
 rename meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
 rename meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
 rename meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
 rename meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
 rename meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
 rename meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
 rename meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
 rename meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
 rename meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
 rename meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
 rename meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch => 0034-guard-clang-tools-extra-test.patch} (83%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
 create mode 100644 meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch

diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
index 2966cddc05..dde6821718 100644
--- a/meta/conf/distro/include/maintainers.inc
+++ b/meta/conf/distro/include/maintainers.inc
@@ -482,7 +482,7 @@ RECIPE_MAINTAINER:pn-linux-yocto-tiny = "Bruce Ashfield <bruce.ashfield@gmail.co
 RECIPE_MAINTAINER:pn-lld = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER:pn-lldb = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER:pn-llvm = "Khem Raj <raj.khem@gmail.com>"
-RECIPE_MAINTAINER:pn-llvm-project-source-22.1.8 = "Khem Raj <raj.khem@gmail.com>"
+RECIPE_MAINTAINER:pn-llvm-project-source-23.1.0 = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER:pn-llvm-tblgen-native = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER:pn-log4cplus = "Unassigned <unassigned@yoctoproject.org>"
 RECIPE_MAINTAINER:pn-logrotate = "Yi Zhao <yi.zhao@windriver.com>"
diff --git a/meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch b/meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
similarity index 90%
rename from meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
rename to meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
index 896bbd11aa..4684fff493 100644
--- a/meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
+++ b/meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
@@ -1,4 +1,4 @@
-From 16b03fccab20cac13065ab99f36a7f0a77a62b92 Mon Sep 17 00:00:00 2001
+From 09798ecb4d4c7f1372e7538666bf9c5199f7ab04 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 19 May 2016 23:11:45 -0700
 Subject: [PATCH] compiler-rt: Simplify cross-compilation. Don't use
@@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 10 insertions(+), 1 deletion(-)
 
 diff --git a/compiler-rt/CMakeLists.txt b/compiler-rt/CMakeLists.txt
-index a92258ae1244..98c4e9a681d5 100644
+index d720b86..60ac56f 100644
 --- a/compiler-rt/CMakeLists.txt
 +++ b/compiler-rt/CMakeLists.txt
-@@ -109,7 +109,16 @@ if (COMPILER_RT_STANDALONE_BUILD)
+@@ -125,7 +125,16 @@ if (COMPILER_RT_STANDALONE_BUILD)
    set(CMAKE_CXX_EXTENSIONS NO)
  
    if (NOT LLVM_RUNTIMES_BUILD)
diff --git a/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch b/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
deleted file mode 100644
index 43221274bf..0000000000
--- a/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 97247b6a1df63a5f930d090a3952876eb67cf6fb Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 27 Aug 2017 10:37:49 -0700
-Subject: [PATCH] libcxxabi: Find libunwind headers when
- LIBCXXABI_LIBUNWIND_INCLUDES is set
-
-Currently, when LIBCXXABI_LIBUNWIND_INCLUDES is set via CMake arguments
-then it ends up not searching the specified dir and unwind.h is not found
-especially for ARM targets
-
-This patch makes the searching synthesized directories and then set
-LIBCXXABI_LIBUNWIND_INCLUDES if its there in environment
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- libcxxabi/CMakeLists.txt | 15 ++++++++++-----
- 1 file changed, 10 insertions(+), 5 deletions(-)
-
-diff --git a/libcxxabi/CMakeLists.txt b/libcxxabi/CMakeLists.txt
-index 2b67c5972339..45d84b404b30 100644
---- a/libcxxabi/CMakeLists.txt
-+++ b/libcxxabi/CMakeLists.txt
-@@ -476,7 +476,7 @@ set(LIBCXXABI_LIBUNWIND_PATH "${LIBCXXABI_LIBUNWIND_PATH}" CACHE PATH
-     "Specify path to libunwind source." FORCE)
- 
- if (LIBCXXABI_USE_LLVM_UNWINDER OR LLVM_NATIVE_ARCH MATCHES ARM)
--  find_path(LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL libunwind.h
-+  find_path(LIBCXXABI_LIBUNWIND_INCLUDES libunwind.h
-     PATHS ${LIBCXXABI_LIBUNWIND_INCLUDES}
-           ${LIBCXXABI_LIBUNWIND_PATH}/include
-           ${CMAKE_BINARY_DIR}/${LIBCXXABI_LIBUNWIND_INCLUDES}
-@@ -487,18 +487,23 @@ if (LIBCXXABI_USE_LLVM_UNWINDER OR LLVM_NATIVE_ARCH MATCHES ARM)
-     NO_CMAKE_FIND_ROOT_PATH
-   )
- 
--  if (LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL STREQUAL "LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL-NOTFOUND")
--    set(LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL "")
-+  if (LIBCXXABI_LIBUNWIND_INCLUDES STREQUAL "LIBCXXABI_LIBUNWIND_INCLUDES-NOTFOUND")
-+    set(LIBCXXABI_LIBUNWIND_INCLUDES "")
-   endif()
- endif()
- 
--if (NOT "${LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL}" STREQUAL "")
--  include_directories("${LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL}")
-+if (NOT "${LIBCXXABI_LIBUNWIND_INCLUDES}" STREQUAL "")
-+  include_directories("${LIBCXXABI_LIBUNWIND_INCLUDES}")
- endif()
- 
- add_custom_target(cxxabi-test-depends
-   COMMENT "Build dependencies required to run the libc++abi test suite.")
- 
-+set(LIBCXXABI_LIBUNWIND_INCLUDES "${LIBCXXABI_LIBUNWIND_INCLUDES}" CACHE PATH
-+    "Specify path to libunwind includes." FORCE)
-+set(LIBCXXABI_LIBUNWIND_PATH "${LIBCXXABI_LIBUNWIND_PATH}" CACHE PATH
-+    "Specify path to libunwind source." FORCE)
-+
- # Add source code. This also contains all of the logic for deciding linker flags
- # soname, etc...
- add_subdirectory(include)
diff --git a/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch b/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
deleted file mode 100644
index 5dcad6b0df..0000000000
--- a/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
+++ /dev/null
@@ -1,309 +0,0 @@
-From eae63772aacba29de729d9af5c52542cd8a043ee Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sun, 19 Apr 2015 15:16:23 -0700
-Subject: [PATCH] compiler-rt: support a new embedded linux target
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- .../make/platform/clang_linux_embedded.mk     | 286 ++++++++++++++++++
- .../clang_linux_embedded_test_input.c         |   0
- 2 files changed, 286 insertions(+)
- create mode 100644 compiler-rt/make/platform/clang_linux_embedded.mk
- create mode 100644 compiler-rt/make/platform/clang_linux_embedded_test_input.c
-
-diff --git a/compiler-rt/make/platform/clang_linux_embedded.mk b/compiler-rt/make/platform/clang_linux_embedded.mk
-new file mode 100644
-index 000000000000..d0a890075a1c
---- /dev/null
-+++ b/compiler-rt/make/platform/clang_linux_embedded.mk
-@@ -0,0 +1,286 @@
-+# These are the functions which clang needs when it is targeting a previous
-+# version of the OS. The issue is that the backend may use functions which were
-+# not present in the libgcc that shipped on the platform. In such cases, we link
-+# with a version of the library which contains private_extern definitions of all
-+# the extra functions which might be referenced.
-+
-+Description := Static runtime libraries for embedded clang/Linux
-+
-+# A function that ensures we don't try to build for architectures that we
-+# don't have working toolchains for.
-+CheckArches = \
-+  $(shell \
-+    result=""; \
-+    for arch in $(1); do \
-+      if $(CC) -arch $$arch -c \
-+	  -integrated-as \
-+	  $(ProjSrcRoot)/make/platform/clang_linux_embedded_test_input.c \
-+	  -o /dev/null > /dev/null 2> /dev/null; then \
-+        result="$$result$$arch "; \
-+      else \
-+	printf 1>&2 \
-+	  "warning: clang_linux_embedded.mk: dropping arch '$$arch' from lib '$(2)'\n"; \
-+      fi; \
-+    done; \
-+    echo $$result)
-+
-+XCRun = \
-+  $(shell \
-+    result=`xcrun -find $(1) 2> /dev/null`; \
-+    if [ "$$?" != "0" ]; then result=$(1); fi; \
-+    echo $$result)
-+
-+###
-+
-+CC       := $(call XCRun,clang)
-+AR       := $(call XCRun,ar)
-+RANLIB   := $(call XCRun,ranlib)
-+STRIP    := $(call XCRun,strip)
-+LIPO     := $(call XCRun,lipo)
-+DSYMUTIL := $(call XCRun,dsymutil)
-+Configs :=
-+UniversalArchs :=
-+
-+# Soft-float version of the runtime. No floating-point instructions will be used
-+# and the ABI (out of necessity) passes floating values in normal registers:
-+# non-VFP variant of the AAPCS.
-+UniversalArchs.soft_static := $(call CheckArches,arm armv7m armv7em armv7,soft_static)
-+Configs += $(if $(UniversalArchs.soft_static),soft_static)
-+
-+# Hard-float version of the runtime. On ARM VFP instructions and registers are
-+# allowed, and floating point values get passed in them. VFP variant of the
-+# AAPCS.
-+UniversalArchs.hard_static := $(call CheckArches,armv7em armv7 i386 x86_64,hard_static)
-+Configs += $(if $(UniversalArchs.hard_static),hard_static)
-+
-+UniversalArchs.soft_pic := $(call CheckArches,armv6m armv7m armv7em armv7,soft_pic)
-+Configs += $(if $(UniversalArchs.soft_pic),soft_pic)
-+
-+UniversalArchs.hard_pic := $(call CheckArches,armv7em armv7 i386 x86_64,hard_pic)
-+Configs += $(if $(UniversalArchs.hard_pic),hard_pic)
-+
-+CFLAGS := -Wall -Werror -Oz -fomit-frame-pointer -ffreestanding
-+
-+PIC_CFLAGS := -fPIC
-+STATIC_CFLAGS := -static
-+
-+CFLAGS_SOFT := -mfloat-abi=soft
-+CFLAGS_HARD := -mfloat-abi=hard
-+
-+CFLAGS_I386  := -march=pentium
-+
-+CFLAGS.soft_static := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_SOFT)
-+CFLAGS.hard_static := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_HARD)
-+CFLAGS.soft_pic    := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_SOFT)
-+CFLAGS.hard_pic    := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_HARD)
-+
-+CFLAGS.soft_static.armv7 := $(CFLAGS.soft_static) $(CFLAGS_ARMV7)
-+CFLAGS.hard_static.armv7 := $(CFLAGS.hard_static) $(CFLAGS_ARMV7)
-+CFLAGS.soft_pic.armv7    := $(CFLAGS.soft_pic) $(CFLAGS_ARMV7)
-+CFLAGS.hard_pic.armv7    := $(CFLAGS.hard_pic) $(CFLAGS_ARMV7)
-+
-+# x86 platforms ignore -mfloat-abi options and complain about doing so. Despite
-+# this they're hard-float.
-+CFLAGS.hard_static.i386   := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_I386)
-+CFLAGS.hard_pic.i386      := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_I386)
-+CFLAGS.hard_static.x86_64 := $(CFLAGS) $(STATIC_CFLAGS)
-+CFLAGS.hard_pic.x86_64    := $(CFLAGS) $(PIC_CFLAGS)
-+
-+# Functions not wanted:
-+#   + eprintf is obsolete anyway
-+#   + *vfp: designed for Thumb1 CPUs with VFPv2
-+
-+COMMON_FUNCTIONS := \
-+	absvdi2 \
-+	absvsi2 \
-+	addvdi3 \
-+	addvsi3 \
-+	ashldi3 \
-+	ashrdi3 \
-+	bswapdi2 \
-+	bswapsi2 \
-+	clzdi2 \
-+	clzsi2 \
-+	cmpdi2 \
-+	ctzdi2 \
-+	ctzsi2 \
-+	divdc3 \
-+	divdi3 \
-+	divsc3 \
-+	divmodsi4 \
-+	udivmodsi4 \
-+	do_global_dtors \
-+	ffsdi2 \
-+	fixdfdi \
-+	fixsfdi \
-+	fixunsdfdi \
-+	fixunsdfsi \
-+	fixunssfdi \
-+	fixunssfsi \
-+	floatdidf \
-+	floatdisf \
-+	floatundidf \
-+	floatundisf \
-+	gcc_bcmp \
-+	lshrdi3 \
-+	moddi3 \
-+	muldc3 \
-+	muldi3 \
-+	mulsc3 \
-+	mulvdi3 \
-+	mulvsi3 \
-+	negdi2 \
-+	negvdi2 \
-+	negvsi2 \
-+	paritydi2 \
-+	paritysi2 \
-+	popcountdi2 \
-+	popcountsi2 \
-+	powidf2 \
-+	powisf2 \
-+	subvdi3 \
-+	subvsi3 \
-+	ucmpdi2 \
-+	udiv_w_sdiv \
-+	udivdi3 \
-+	udivmoddi4 \
-+	umoddi3 \
-+	adddf3 \
-+	addsf3 \
-+	cmpdf2 \
-+	cmpsf2 \
-+	div0 \
-+	divdf3 \
-+	divsf3 \
-+	divsi3 \
-+	extendsfdf2 \
-+	ffssi2 \
-+	fixdfsi \
-+	fixsfsi \
-+	floatsidf \
-+	floatsisf \
-+	floatunsidf \
-+	floatunsisf \
-+	comparedf2 \
-+	comparesf2 \
-+	modsi3 \
-+	muldf3 \
-+	mulsf3 \
-+	negdf2 \
-+	negsf2 \
-+	subdf3 \
-+	subsf3 \
-+	truncdfsf2 \
-+	udivsi3 \
-+	umodsi3 \
-+	unorddf2 \
-+	unordsf2
-+
-+ARM_FUNCTIONS := \
-+	aeabi_cdcmpeq \
-+	aeabi_cdrcmple \
-+	aeabi_cfcmpeq \
-+	aeabi_cfrcmple \
-+	aeabi_dcmpeq \
-+	aeabi_dcmpge \
-+	aeabi_dcmpgt \
-+	aeabi_dcmple \
-+	aeabi_dcmplt \
-+	aeabi_drsub \
-+	aeabi_fcmpeq \
-+	aeabi_fcmpge \
-+	aeabi_fcmpgt \
-+	aeabi_fcmple \
-+	aeabi_fcmplt \
-+	aeabi_frsub \
-+	aeabi_idivmod \
-+	aeabi_uidivmod \
-+
-+# ARM Assembly implementation which requires Thumb2 (i.e. won't work on v6M).
-+THUMB2_FUNCTIONS := \
-+	switch16 \
-+	switch32 \
-+	switch8 \
-+	switchu8 \
-+	sync_fetch_and_add_4 \
-+	sync_fetch_and_sub_4 \
-+	sync_fetch_and_and_4 \
-+	sync_fetch_and_or_4 \
-+	sync_fetch_and_xor_4 \
-+	sync_fetch_and_nand_4 \
-+	sync_fetch_and_max_4 \
-+	sync_fetch_and_umax_4 \
-+	sync_fetch_and_min_4 \
-+	sync_fetch_and_umin_4 \
-+	sync_fetch_and_add_8 \
-+	sync_fetch_and_sub_8 \
-+	sync_fetch_and_and_8 \
-+	sync_fetch_and_or_8 \
-+	sync_fetch_and_xor_8 \
-+	sync_fetch_and_nand_8 \
-+	sync_fetch_and_max_8 \
-+	sync_fetch_and_umax_8 \
-+	sync_fetch_and_min_8 \
-+	sync_fetch_and_umin_8
-+
-+I386_FUNCTIONS :=  \
-+	i686.get_pc_thunk.eax \
-+	i686.get_pc_thunk.ebp \
-+	i686.get_pc_thunk.ebx \
-+	i686.get_pc_thunk.ecx \
-+	i686.get_pc_thunk.edi \
-+	i686.get_pc_thunk.edx \
-+	i686.get_pc_thunk.esi
-+
-+# FIXME: Currently, compiler-rt is missing implementations for a number of the
-+# functions. Filter them out for now.
-+MISSING_FUNCTIONS := \
-+	cmpdf2 cmpsf2 div0 \
-+	ffssi2 \
-+	udiv_w_sdiv unorddf2 unordsf2 bswapdi2 \
-+	bswapsi2 \
-+	gcc_bcmp \
-+	do_global_dtors \
-+	i686.get_pc_thunk.eax i686.get_pc_thunk.ebp i686.get_pc_thunk.ebx \
-+	i686.get_pc_thunk.ecx i686.get_pc_thunk.edi i686.get_pc_thunk.edx \
-+	i686.get_pc_thunk.esi \
-+	aeabi_cdcmpeq aeabi_cdrcmple aeabi_cfcmpeq aeabi_cfrcmple aeabi_dcmpeq \
-+	aeabi_dcmpge aeabi_dcmpgt aeabi_dcmple aeabi_dcmplt aeabi_drsub \
-+	aeabi_fcmpeq \ aeabi_fcmpge aeabi_fcmpgt aeabi_fcmple aeabi_fcmplt \
-+	aeabi_frsub aeabi_idivmod aeabi_uidivmod
-+
-+FUNCTIONS_ARMV6M  := $(COMMON_FUNCTIONS) $(ARM_FUNCTIONS)
-+FUNCTIONS_ARM_ALL := $(COMMON_FUNCTIONS) $(ARM_FUNCTIONS) $(THUMB2_FUNCTIONS)
-+FUNCTIONS_I386    := $(COMMON_FUNCTIONS) $(I386_FUNCTIONS)
-+FUNCTIONS_X86_64  := $(COMMON_FUNCTIONS)
-+
-+FUNCTIONS_ARMV6M := \
-+	$(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_ARMV6M))
-+FUNCTIONS_ARM_ALL := \
-+	$(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_ARM_ALL))
-+FUNCTIONS_I386 := \
-+	$(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_I386))
-+FUNCTIONS_X86_64 := \
-+	$(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_X86_64))
-+
-+FUNCTIONS.soft_static.armv6m := $(FUNCTIONS_ARMV6M)
-+FUNCTIONS.soft_pic.armv6m    := $(FUNCTIONS_ARMV6M)
-+
-+FUNCTIONS.soft_static.armv7m := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.soft_pic.armv7m    := $(FUNCTIONS_ARM_ALL)
-+
-+FUNCTIONS.soft_static.armv7em := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_static.armv7em := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.soft_pic.armv7em    := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_pic.armv7em    := $(FUNCTIONS_ARM_ALL)
-+
-+FUNCTIONS.soft_static.armv7 := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_static.armv7 := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.soft_pic.armv7    := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_pic.armv7    := $(FUNCTIONS_ARM_ALL)
-+
-+FUNCTIONS.hard_static.i386 := $(FUNCTIONS_I386)
-+FUNCTIONS.hard_pic.i386    := $(FUNCTIONS_I386)
-+
-+FUNCTIONS.hard_static.x86_64 := $(FUNCTIONS_X86_64)
-+FUNCTIONS.hard_pic.x86_64    := $(FUNCTIONS_X86_64)
-diff --git a/compiler-rt/make/platform/clang_linux_embedded_test_input.c b/compiler-rt/make/platform/clang_linux_embedded_test_input.c
-new file mode 100644
-index 000000000000..e69de29bb2d1
diff --git a/meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch b/meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
similarity index 96%
rename from meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
rename to meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
index 3c7c274693..583718c6ee 100644
--- a/meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
+++ b/meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
@@ -1,4 +1,4 @@
-From d13464858866ff3c0026294d6842f74a11a0d625 Mon Sep 17 00:00:00 2001
+From 9aa64eaa942dad120bc6baaf17d6d859049f9de9 Mon Sep 17 00:00:00 2001
 From: Martin Kelly <mkelly@xevo.com>
 Date: Fri, 19 May 2017 00:22:57 -0700
 Subject: [PATCH] llvm: allow env override of exe and libdir path
@@ -19,7 +19,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 19 insertions(+), 6 deletions(-)
 
 diff --git a/llvm/tools/llvm-config/llvm-config.cpp b/llvm/tools/llvm-config/llvm-config.cpp
-index 24ea264419af..0a3f51ae2b83 100644
+index 76aa9f8..64795e9 100644
 --- a/llvm/tools/llvm-config/llvm-config.cpp
 +++ b/llvm/tools/llvm-config/llvm-config.cpp
 @@ -248,6 +248,13 @@ Typical components:\n\
diff --git a/meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch b/meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
similarity index 87%
rename from meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch
rename to meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
index e4636d30d1..d68dc94b03 100644
--- a/meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch
+++ b/meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
@@ -1,4 +1,4 @@
-From 7a12ad3232dd6881ca40d94277ca8064a12d9df6 Mon Sep 17 00:00:00 2001
+From 6d26dbc005701acc1dbbd9e05e8596328a7d58f1 Mon Sep 17 00:00:00 2001
 From: Dan McGregor <dan.mcgregor@usask.ca>
 Date: Wed, 26 Apr 2017 20:29:41 -0600
 Subject: [PATCH] clang: driver: Check sysroot for ldso path
@@ -17,10 +17,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 21 insertions(+), 1 deletion(-)
 
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index d525b417b4ea..1c31901ade74 100644
+index 8d30a5e..1958c64 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -630,8 +630,12 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -645,8 +645,12 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
          Triple.getEnvironment() == llvm::Triple::GNUEABIHFT64 ||
          tools::arm::getARMFloatABI(*this, Args) == tools::arm::FloatABI::Hard;
  
@@ -34,7 +34,7 @@ index d525b417b4ea..1c31901ade74 100644
      break;
    }
    case llvm::Triple::loongarch32: {
-@@ -685,11 +689,19 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -700,11 +704,19 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
      LibDir = "lib64";
      Loader =
          (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
@@ -53,8 +53,8 @@ index d525b417b4ea..1c31901ade74 100644
 +    }
      break;
    case llvm::Triple::riscv32:
-   case llvm::Triple::riscv64: {
-@@ -707,6 +719,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+   case llvm::Triple::riscv64:
+@@ -724,6 +736,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
    case llvm::Triple::sparcv9:
      LibDir = "lib64";
      Loader = "ld-linux.so.2";
@@ -65,7 +65,7 @@ index d525b417b4ea..1c31901ade74 100644
      break;
    case llvm::Triple::systemz:
      LibDir = "lib";
-@@ -721,6 +737,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -738,6 +754,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
  
      LibDir = X32 ? "libx32" : "lib64";
      Loader = X32 ? "ld-linux-x32.so.2" : "ld-linux-x86-64.so.2";
diff --git a/meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch b/meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
rename to meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
index 0269dece67..1ba19bb4cd 100644
--- a/meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
+++ b/meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
@@ -1,4 +1,4 @@
-From 19b8ca2e1aa536e7d7f7eb379fc4e4d6f1efd07a Mon Sep 17 00:00:00 2001
+From 64a5c3e2680fb2a04ecba015af8eb5049c4840e1 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 19 May 2016 21:11:06 -0700
 Subject: [PATCH] clang: Driver/tools.cpp: Add -lssp_nonshared on musl
@@ -14,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 6 insertions(+)
 
 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index cb6a9b242421..8f126474b7d1 100644
+index 24076d8..a7a64fc 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -539,6 +539,12 @@ void tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
+@@ -537,6 +537,12 @@ void tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
        if (IsIAMCU)
          CmdArgs.push_back("-lgloss");
  
diff --git a/meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch b/meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
similarity index 81%
rename from meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch
rename to meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
index 321de79c78..0de2208a0f 100644
--- a/meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch
+++ b/meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
@@ -1,4 +1,4 @@
-From 1746960b385afbc9e8e355a3b7c66b43c946451b Mon Sep 17 00:00:00 2001
+From e6285791435950771c13b442319efdcd6a21d81e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 16 Mar 2017 09:02:13 -0700
 Subject: [PATCH] clang: Prepend trailing '/' to sysroot
@@ -25,12 +25,12 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 1c31901ade74..f7f096c1ac0a 100644
+index 1958c64..cb2b227 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -235,7 +235,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
-   Multilibs = GCCInstallation.getMultilibs();
-   SelectedMultilibs.assign({GCCInstallation.getMultilib()});
+@@ -238,7 +238,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+   loadMultilibsFromYAML(Args, D);
+ 
    llvm::Triple::ArchType Arch = Triple.getArch();
 -  std::string SysRoot = computeSysRoot();
 +  std::string SysRoot = computeSysRoot() + "/";
diff --git a/meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch b/meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
similarity index 94%
rename from meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch
rename to meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
index 38470e9834..427842a07a 100644
--- a/meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch
+++ b/meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
@@ -1,4 +1,4 @@
-From bfba4232621e151cfc5dcb16ce5bf661f8c3d8f8 Mon Sep 17 00:00:00 2001
+From 04e0958fea64ebc9c89c0a6c147e8806a87727bd Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 20 Mar 2021 16:09:16 -0700
 Subject: [PATCH] clang: Define / releative gcc installation dir
@@ -61,7 +61,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 14 insertions(+), 8 deletions(-)
 
 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index 8f126474b7d1..c80980a7fb09 100644
+index a7a64fc..f44663f 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
 @@ -18,6 +18,7 @@
@@ -72,7 +72,7 @@ index 8f126474b7d1..c80980a7fb09 100644
  #include "clang/Driver/Driver.h"
  #include "clang/Driver/MultilibBuilder.h"
  #include "clang/Driver/Tool.h"
-@@ -2847,6 +2848,7 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
+@@ -2869,6 +2870,7 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
      const llvm::Triple &TargetTriple, const ArgList &Args,
      const std::string &LibDir, StringRef CandidateTriple,
      bool NeedsBiarchSuffix, bool GCCDirExists, bool GCCCrossDirExists) {
@@ -80,7 +80,7 @@ index 8f126474b7d1..c80980a7fb09 100644
    // Locations relative to the system lib directory where GCC's triple-specific
    // directories might reside.
    struct GCCLibSuffix {
-@@ -2858,19 +2860,20 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
+@@ -2880,19 +2882,20 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
      // Whether this library suffix is relevant for the triple.
      bool Active;
    } Suffixes[] = {
@@ -108,7 +108,7 @@ index 8f126474b7d1..c80980a7fb09 100644
  
    SmallVector<GCCInstallCandidate, 3> Installations;
    for (auto &Suffix : Suffixes) {
-@@ -3273,8 +3276,11 @@ Generic_GCC::addLibCxxIncludePaths(const llvm::opt::ArgList &DriverArgs,
+@@ -3297,8 +3300,11 @@ Generic_GCC::addLibCxxIncludePaths(const llvm::opt::ArgList &DriverArgs,
    // incompatible with the NDK libraries.
    SmallString<128> DriverIncludeDir(getDriver().Dir);
    llvm::sys::path::append(DriverIncludeDir, "..", "include");
diff --git a/meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch b/meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
rename to meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
index b338d0f570..e07f004fb4 100644
--- a/meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
+++ b/meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
@@ -1,8 +1,8 @@
-From 03875620d0172a7c07e3cdc607a6877b06a130e9 Mon Sep 17 00:00:00 2001
+From f64b2adab7e4c515aa1e082054ad4514898e2d5d Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 31 Jul 2019 22:51:39 -0700
-Subject: [PATCH] clang: Add -lpthread and -ldl along with -lunwind for static
- linking
+Subject: [PATCH] clang: Add -lpthread and -ldl along with -lunwind for
+ static linking
 
 When doing static liking with --unwindlib=libunwind -static we encounter
 undefined symbols
@@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 2 insertions(+)
 
 diff --git a/clang/lib/Driver/ToolChains/CommonArgs.cpp b/clang/lib/Driver/ToolChains/CommonArgs.cpp
-index 10a1a412eea0..a217897610c3 100644
+index 08c0695..362e7ca 100644
 --- a/clang/lib/Driver/ToolChains/CommonArgs.cpp
 +++ b/clang/lib/Driver/ToolChains/CommonArgs.cpp
-@@ -2415,6 +2415,8 @@ static void AddUnwindLibrary(const ToolChain &TC, const Driver &D,
+@@ -2484,6 +2484,8 @@ static void AddUnwindLibrary(const ToolChain &TC, const Driver &D,
          CmdArgs.push_back("-lunwind");
      } else if (LGT == LibGccType::StaticLibGcc) {
        CmdArgs.push_back("-l:libunwind.a");
diff --git a/meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch b/meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch
rename to meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
index ba6a5c1510..c9764c70e9 100644
--- a/meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch
+++ b/meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
@@ -1,4 +1,4 @@
-From ea4326b11976e48dde6d99605ac24df048cd3b10 Mon Sep 17 00:00:00 2001
+From a4a94de113dce4cf88c05bf0d5628a902ed93ff3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Mon, 18 Nov 2019 17:00:29 -0800
 Subject: [PATCH] Check for atomic<double> intrinsics
@@ -16,7 +16,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/llvm/cmake/modules/CheckAtomic.cmake b/llvm/cmake/modules/CheckAtomic.cmake
-index f11cadf39ff6..80a18a92956a 100644
+index f11cadf..80a18a9 100644
 --- a/llvm/cmake/modules/CheckAtomic.cmake
 +++ b/llvm/cmake/modules/CheckAtomic.cmake
 @@ -30,10 +30,11 @@ function(check_working_cxx_atomics64 varname)
diff --git a/meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch b/meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
similarity index 89%
rename from meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch
rename to meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
index 946eb1661f..2a3744f225 100644
--- a/meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch
+++ b/meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
@@ -1,4 +1,4 @@
-From dc281691e778a61cc14bca4eb187792d2ffb384c Mon Sep 17 00:00:00 2001
+From d373417d4724071c98f95d17c88cc78e9dc1c241 Mon Sep 17 00:00:00 2001
 From: Ovidiu Panait <ovidiu.panait@windriver.com>
 Date: Fri, 31 Jan 2020 10:56:11 +0200
 Subject: [PATCH] cmake: Fix configure for packages using find_package()
@@ -31,7 +31,7 @@ Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
  3 files changed, 2 insertions(+), 15 deletions(-)
 
 diff --git a/clang/cmake/modules/AddClang.cmake b/clang/cmake/modules/AddClang.cmake
-index 4059fc3e986c..44d43aa8f25b 100644
+index e2112d7..f51983d 100644
 --- a/clang/cmake/modules/AddClang.cmake
 +++ b/clang/cmake/modules/AddClang.cmake
 @@ -182,7 +182,6 @@ macro(add_clang_tool name)
@@ -51,10 +51,10 @@ index 4059fc3e986c..44d43aa8f25b 100644
    endif()
    set_target_properties(${name} PROPERTIES XCODE_GENERATE_SCHEME ON)
 diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake
-index d938214f9d0d..4816f2127e14 100644
+index a267166..09ff2af 100644
 --- a/llvm/cmake/modules/AddLLVM.cmake
 +++ b/llvm/cmake/modules/AddLLVM.cmake
-@@ -1485,7 +1485,6 @@ macro(llvm_add_tool project name)
+@@ -1625,7 +1625,6 @@ macro(llvm_add_tool project name)
        if( LLVM_BUILD_TOOLS )
          get_target_export_arg(${name} ${project} export_to_llvmexports)
          install(TARGETS ${name}
@@ -62,7 +62,7 @@ index d938214f9d0d..4816f2127e14 100644
                  RUNTIME DESTINATION ${${project}_TOOLS_INSTALL_DIR}
                  COMPONENT ${name})
          if (LLVM_ENABLE_PDB)
-@@ -1501,10 +1500,8 @@ macro(llvm_add_tool project name)
+@@ -1641,10 +1640,8 @@ macro(llvm_add_tool project name)
          endif()
        endif()
      endif()
@@ -75,7 +75,7 @@ index d938214f9d0d..4816f2127e14 100644
    endif()
    get_subproject_title(subproject_title)
    set_target_properties(${name} PROPERTIES FOLDER "${subproject_title}/Tools")
-@@ -1559,7 +1556,6 @@ macro(add_llvm_utility name)
+@@ -1699,7 +1696,6 @@ macro(add_llvm_utility name)
      if (LLVM_INSTALL_UTILS AND LLVM_BUILD_UTILS)
        get_target_export_arg(${name} LLVM export_to_llvmexports)
        install(TARGETS ${name}
@@ -83,7 +83,7 @@ index d938214f9d0d..4816f2127e14 100644
                RUNTIME DESTINATION ${LLVM_UTILS_INSTALL_DIR}
                COMPONENT ${name})
        if (LLVM_ENABLE_PDB)
-@@ -1573,7 +1569,6 @@ macro(add_llvm_utility name)
+@@ -1713,7 +1709,6 @@ macro(add_llvm_utility name)
                                   DEPENDS ${name}
                                   COMPONENT ${name})
        endif()
@@ -92,10 +92,10 @@ index d938214f9d0d..4816f2127e14 100644
        set_property(GLOBAL APPEND PROPERTY LLVM_EXPORTS_BUILDTREE_ONLY ${name})
      endif()
 diff --git a/llvm/cmake/modules/TableGen.cmake b/llvm/cmake/modules/TableGen.cmake
-index 84c03cd6432e..72da60ce3ca1 100644
+index 397089a..5240962 100644
 --- a/llvm/cmake/modules/TableGen.cmake
 +++ b/llvm/cmake/modules/TableGen.cmake
-@@ -237,12 +237,7 @@ macro(add_tablegen target project)
+@@ -239,12 +239,7 @@ macro(add_tablegen target project)
  
    if (ADD_TABLEGEN_DESTINATION AND NOT LLVM_INSTALL_TOOLCHAIN_ONLY AND
        (LLVM_BUILD_UTILS OR ${target} IN_LIST LLVM_DISTRIBUTION_COMPONENTS))
@@ -108,7 +108,7 @@ index 84c03cd6432e..72da60ce3ca1 100644
              COMPONENT ${target}
              RUNTIME DESTINATION "${ADD_TABLEGEN_DESTINATION}")
      if(NOT LLVM_ENABLE_IDE)
-@@ -253,7 +248,6 @@ macro(add_tablegen target project)
+@@ -255,7 +250,6 @@ macro(add_tablegen target project)
    endif()
    if(ADD_TABLEGEN_EXPORT)
      string(TOUPPER ${ADD_TABLEGEN_EXPORT} export_upper)
diff --git a/meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch b/meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
similarity index 95%
rename from meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
rename to meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
index 72b989c0a2..df6c44bca1 100644
--- a/meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
+++ b/meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
@@ -1,4 +1,4 @@
-From 248a51bece02c199d0f84d14fa7e2e2379c592a0 Mon Sep 17 00:00:00 2001
+From d03df63cfd772452b5b7c8ddb587f576f054b004 Mon Sep 17 00:00:00 2001
 From: Jim Broadus <jbroadus@xevo.com>
 Date: Thu, 26 Mar 2020 16:05:53 -0700
 Subject: [PATCH] clang: Fix resource dir location for cross toolchains
@@ -21,7 +21,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 8 insertions(+), 1 deletion(-)
 
 diff --git a/clang/lib/Options/OptionUtils.cpp b/clang/lib/Options/OptionUtils.cpp
-index e5aefa012f67..7c1b657ce2c1 100644
+index 77f8955..62bb694 100644
 --- a/clang/lib/Options/OptionUtils.cpp
 +++ b/clang/lib/Options/OptionUtils.cpp
 @@ -213,6 +213,7 @@ std::string clang::GetResourcesPath(StringRef BinaryPath) {
diff --git a/meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch b/meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
similarity index 88%
rename from meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
rename to meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
index 725d10a2a7..29d7a6d6bc 100644
--- a/meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
+++ b/meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
@@ -1,8 +1,8 @@
-From b3eea8bcdb792a7b19b879c76eac64f36d1fe012 Mon Sep 17 00:00:00 2001
+From 75e6420bd7f45f1b60a856d51866e22d83cf55b0 Mon Sep 17 00:00:00 2001
 From: Oleksandr Ocheretnyi <oocheret@cisco.com>
 Date: Wed, 15 Apr 2020 00:08:39 +0300
-Subject: [PATCH] clang: driver: Add dyld-prefix when checking sysroot for ldso
- path
+Subject: [PATCH] clang: driver: Add dyld-prefix when checking sysroot
+ for ldso path
 
  * the dyld-prefix shall be taken into account when the default
    path for the dynamic linker has to be checked.
@@ -19,10 +19,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 10 insertions(+), 10 deletions(-)
 
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index f7f096c1ac0a..7b608a84a66e 100644
+index cb2b227..c2ac9b6 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -632,8 +632,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -647,8 +647,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
  
      Loader = HF ? "ld-linux-armhf.so.3" : "ld-linux.so.3";
      LibDir = "lib32";
@@ -33,7 +33,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -689,8 +689,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -704,8 +704,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
      LibDir = "lib64";
      Loader =
          (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
@@ -44,7 +44,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -698,8 +698,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -713,8 +713,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
      LibDir = "lib64";
      Loader =
          (tools::ppc::hasPPCAbiArg(Args, "elfv1")) ? "ld64.so.1" : "ld64.so.2";
@@ -55,7 +55,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -719,8 +719,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -736,8 +736,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
    case llvm::Triple::sparcv9:
      LibDir = "lib64";
      Loader = "ld-linux.so.2";
@@ -66,7 +66,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -737,8 +737,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -754,8 +754,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
  
      LibDir = X32 ? "libx32" : "lib64";
      Loader = X32 ? "ld-linux-x32.so.2" : "ld-linux-x86-64.so.2";
diff --git a/meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch b/meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
similarity index 90%
rename from meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch
rename to meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
index e29d23cab2..5b0a0b3431 100644
--- a/meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch
+++ b/meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
@@ -1,4 +1,4 @@
-From 17e1af5e12a01296d2c032a768569d4d8b06505b Mon Sep 17 00:00:00 2001
+From bc161f33adb168a0a1614d38eb84190c3f690000 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 14 Oct 2020 22:19:57 -0700
 Subject: [PATCH] clang: Use python3 in python scripts
@@ -14,7 +14,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  2 files changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py b/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
-index 49a1b1493264..6158876d15f7 100755
+index 49a1b14..6158876 100755
 --- a/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
 +++ b/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
 @@ -1,4 +1,4 @@
@@ -24,7 +24,7 @@ index 49a1b1493264..6158876d15f7 100755
  # =- run-find-all-symbols.py - Parallel find-all-symbols runner -*- python  -*-=#
  #
 diff --git a/clang/tools/scan-view/bin/scan-view b/clang/tools/scan-view/bin/scan-view
-index d01aebb4029a..f3375804654d 100755
+index d01aebb..f337580 100755
 --- a/clang/tools/scan-view/bin/scan-view
 +++ b/clang/tools/scan-view/bin/scan-view
 @@ -1,4 +1,4 @@
diff --git a/meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch b/meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
rename to meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
index 674a3b264e..aba7488323 100644
--- a/meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
+++ b/meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
@@ -1,7 +1,8 @@
-From 259d8eb2ed82c9248387a3cbb1befee358ecbb8e Mon Sep 17 00:00:00 2001
+From 12fbb32963d7aad6c0d5a0ca5fc0f536f1a9b4fe Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com>
 Date: Mon, 25 Jan 2021 16:14:35 +0800
-Subject: [PATCH] llvm/clang: Insert anchor for adding OE distro vendor names
+Subject: [PATCH] llvm/clang: Insert anchor for adding OE distro vendor
+ names
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
@@ -99,11 +100,11 @@ Signed-off-by: João Marcos Costa <joaomarcos.costa@bootlin.com>
  clang/lib/Driver/Distro.cpp           | 1 +
  clang/lib/Driver/ToolChains/Gnu.cpp   | 1 +
  clang/lib/Driver/ToolChains/Linux.cpp | 2 ++
- llvm/lib/TargetParser/Triple.cpp      | 2 +-
- 5 files changed, 7 insertions(+), 1 deletion(-)
+ llvm/lib/TargetParser/Triple.cpp      | 1 +
+ 5 files changed, 7 insertions(+)
 
 diff --git a/clang/include/clang/Driver/Distro.h b/clang/include/clang/Driver/Distro.h
-index 0e17b30eb..b449a62dc 100644
+index aa4b3e1..2d77a2b 100644
 --- a/clang/include/clang/Driver/Distro.h
 +++ b/clang/include/clang/Driver/Distro.h
 @@ -45,6 +45,7 @@ public:
@@ -114,7 +115,7 @@ index 0e17b30eb..b449a62dc 100644
      OpenSUSE,
      UbuntuQuantal,
      UbuntuRaring,
-@@ -132,6 +133,7 @@ public:
+@@ -133,6 +134,7 @@ public:
  
    bool IsGentoo() const { return DistroVal == Gentoo; }
  
@@ -123,7 +124,7 @@ index 0e17b30eb..b449a62dc 100644
  };
  
 diff --git a/clang/lib/Driver/Distro.cpp b/clang/lib/Driver/Distro.cpp
-index df10458d0..61dc127a4 100644
+index 585497e..3b58ac7 100644
 --- a/clang/lib/Driver/Distro.cpp
 +++ b/clang/lib/Driver/Distro.cpp
 @@ -43,6 +43,7 @@ static Distro::DistroType DetectOsRelease(llvm::vfs::FileSystem &VFS) {
@@ -135,10 +136,10 @@ index df10458d0..61dc127a4 100644
    return Version;
  }
 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index c80980a7f..80fd8058b 100644
+index f44663f..73ff1f4 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2370,6 +2370,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
+@@ -2371,6 +2371,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
        "x86_64-pc-linux-gnu",    "x86_64-redhat-linux6E",
        "x86_64-redhat-linux",    "x86_64-suse-linux",
        "x86_64-manbo-linux-gnu", "x86_64-slackware-linux",
@@ -147,7 +148,7 @@ index c80980a7f..80fd8058b 100644
    static const char *const X32Triples[] = {"x86_64-linux-gnux32",
                                             "x86_64-pc-linux-gnux32"};
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 7b608a84a..585a86a2d 100644
+index c2ac9b6..3231f36 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
 @@ -45,6 +45,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
@@ -167,18 +168,14 @@ index 7b608a84a..585a86a2d 100644
    case llvm::Triple::aarch64:
      if (IsAndroid)
 diff --git a/llvm/lib/TargetParser/Triple.cpp b/llvm/lib/TargetParser/Triple.cpp
-index a4f9dd42c..86b74451e 100644
+index 356782c..883e654 100644
 --- a/llvm/lib/TargetParser/Triple.cpp
 +++ b/llvm/lib/TargetParser/Triple.cpp
-@@ -702,7 +702,7 @@ static Triple::VendorType parseVendor(StringRef VendorName) {
-       .Case("suse", Triple::SUSE)
-       .Case("oe", Triple::OpenEmbedded)
-       .Case("intel", Triple::Intel)
--      .Case("meta", Triple::Meta)
-+      .Case("meta", Triple::Meta) //CLANG_EXTRA_OE_VENDORS_CASES
+@@ -741,6 +741,7 @@ static Triple::VendorType parseVendor(StringRef VendorName) {
+ #define TRIPLE_VENDOR(Enum, Name) .Case(Name, Triple::Enum)
+ #define TRIPLE_VENDOR_ALIAS(Enum, AliasName) .Case(AliasName, Triple::Enum)
+ #include "llvm/TargetParser/TripleName.def"
++      //CLANG_EXTRA_OE_VENDORS_CASES
        .Default(Triple::UnknownVendor);
  }
  
--- 
-2.39.5
-
diff --git a/meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch b/meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
rename to meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
index 786ff426d3..d54859c338 100644
--- a/meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
+++ b/meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
@@ -1,7 +1,8 @@
-From 6839ba1413cf09eb14a24eeda44fb02c1c6809e1 Mon Sep 17 00:00:00 2001
+From 0a569622e3ebdb2ebd1a2a4f9553161c1bd188d8 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 19 May 2021 17:56:03 -0700
-Subject: [PATCH] clang: Fix x86 triple for non-debian multiarch linux distros
+Subject: [PATCH] clang: Fix x86 triple for non-debian multiarch linux
+ distros
 
 OpenEmbedded does not hardcode mutli-arch like debian therefore ensure
 that it still uses the proper tuple
@@ -13,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 4a0adedce09a..9fed904c05c2 100644
+index 3231f36..41e0017 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -227,8 +227,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+@@ -228,8 +228,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
      : Generic_ELF(D, Triple, Args) {
    GCCInstallation.TripleToDebianMultiarch = [](const llvm::Triple &T) {
      StringRef TripleStr = T.str();
diff --git a/meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch b/meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
similarity index 89%
rename from meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch
rename to meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
index 0b7966ee57..2beff16173 100644
--- a/meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch
+++ b/meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
@@ -1,4 +1,4 @@
-From bf7c0933d65eb811c993ff32fdc6b65f6befc5af Mon Sep 17 00:00:00 2001
+From 1ab2bd0edf76583f0e430da5ef8a53ca4029455f Mon Sep 17 00:00:00 2001
 From: Maksim Kita <maksim-kita@yandex-team.ru>
 Date: Sun, 23 May 2021 10:27:29 +0000
 Subject: [PATCH] libunwind: Added unw_backtrace method
@@ -12,7 +12,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  2 files changed, 21 insertions(+)
 
 diff --git a/libunwind/include/libunwind.h b/libunwind/include/libunwind.h
-index 56ca7110274a..60a27f28100b 100644
+index 6c2dfe5..602cafb 100644
 --- a/libunwind/include/libunwind.h
 +++ b/libunwind/include/libunwind.h
 @@ -235,6 +235,7 @@ extern int unw_is_signal_frame(unw_cursor_t *) LIBUNWIND_AVAIL;
@@ -24,10 +24,10 @@ index 56ca7110274a..60a27f28100b 100644
  extern unw_addr_space_t unw_local_addr_space;
  
 diff --git a/libunwind/src/libunwind.cpp b/libunwind/src/libunwind.cpp
-index 7ffffc2a30c0..ed0b394cb002 100644
+index 0b9d56e..fbfbd48 100644
 --- a/libunwind/src/libunwind.cpp
 +++ b/libunwind/src/libunwind.cpp
-@@ -531,6 +531,26 @@ int __unw_remove_find_dynamic_unwind_sections(
+@@ -527,6 +527,26 @@ int __unw_remove_find_dynamic_unwind_sections(
  
  #endif // __APPLE__
  
diff --git a/meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch b/meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
similarity index 92%
rename from meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch
rename to meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
index b9f7270f62..45a71fc2ab 100644
--- a/meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch
+++ b/meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
@@ -1,4 +1,4 @@
-From 94c6e940ddc44922ee505993549477a0fa7ac50d Mon Sep 17 00:00:00 2001
+From 765a550228a57f9bf88ea2c284a5aec01c4c220e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 8 Feb 2022 01:31:26 -0800
 Subject: [PATCH] lldb: Link with libatomic on x86
@@ -17,7 +17,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 4 insertions(+)
 
 diff --git a/lldb/source/Utility/CMakeLists.txt b/lldb/source/Utility/CMakeLists.txt
-index 04f1692e53b3..da0a48d9da54 100644
+index c0d0a42..463c0d7 100644
 --- a/lldb/source/Utility/CMakeLists.txt
 +++ b/lldb/source/Utility/CMakeLists.txt
 @@ -19,6 +19,10 @@ if (CMAKE_SYSTEM_NAME MATCHES "Windows")
diff --git a/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
deleted file mode 100644
index 3fa436d526..0000000000
--- a/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From bc8371eb77cca413ccb4ebf8239c597f7be40006 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 19 May 2021 17:32:13 -0700
-Subject: [PATCH] compiler-rt: Do not use backtrace APIs on non-glibc linux
-
-musl e.g. does not provide backtrace APIs
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- .../lib/gwp_asan/optional/backtrace_linux_libc.cpp  | 13 ++++++++++++-
- 1 file changed, 12 insertions(+), 1 deletion(-)
-
-diff --git a/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp b/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
-index ea8e72be287d..0344074dd254 100644
---- a/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
-+++ b/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
-@@ -7,7 +7,9 @@
- //===----------------------------------------------------------------------===//
- 
- #include <assert.h>
-+#ifdef __GLIBC__
- #include <execinfo.h>
-+#endif
- #include <stddef.h>
- #include <stdint.h>
- #include <stdlib.h>
-@@ -21,8 +23,11 @@
- namespace {
- size_t Backtrace(uintptr_t *TraceBuffer, size_t Size) {
-   static_assert(sizeof(uintptr_t) == sizeof(void *), "uintptr_t is not void*");
--
-+#ifdef __GLIBC__
-   return backtrace(reinterpret_cast<void **>(TraceBuffer), Size);
-+#else
-+  return -1;
-+#endif
- }
- 
- // We don't need any custom handling for the Segv backtrace - the libc unwinder
-@@ -30,7 +35,11 @@ size_t Backtrace(uintptr_t *TraceBuffer, size_t Size) {
- // to avoid the additional frame.
- GWP_ASAN_ALWAYS_INLINE size_t SegvBacktrace(uintptr_t *TraceBuffer, size_t Size,
-                                             void * /*Context*/) {
-+#ifdef __GLIBC__
-   return Backtrace(TraceBuffer, Size);
-+#else
-+  return -1;
-+#endif
- }
- 
- static void PrintBacktrace(uintptr_t *Trace, size_t TraceLength,
-@@ -40,6 +49,7 @@ static void PrintBacktrace(uintptr_t *Trace, size_t TraceLength,
-     return;
-   }
- 
-+#ifdef __GLIBC__
-   char **BacktraceSymbols =
-       backtrace_symbols(reinterpret_cast<void **>(Trace), TraceLength);
- 
-@@ -53,6 +63,7 @@ static void PrintBacktrace(uintptr_t *Trace, size_t TraceLength,
-   Printf("\n");
-   if (BacktraceSymbols)
-     free(BacktraceSymbols);
-+#endif
- }
- } // anonymous namespace
- 
diff --git a/meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
similarity index 77%
rename from meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch
rename to meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
index 89b492b877..12749e8f96 100644
--- a/meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch
+++ b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
@@ -1,4 +1,4 @@
-From 968515d7aa2d7e4af5f318618c307dbe21538650 Mon Sep 17 00:00:00 2001
+From 3a7b96edc836c0264206f01f5fc7e0cd1bc6c70c Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Wed, 9 Mar 2022 16:28:16 -0800
 Subject: [PATCH] compiler-rt: Enable __int128 for ppc32
@@ -6,15 +6,15 @@ Subject: [PATCH] compiler-rt: Enable __int128 for ppc32
 Upstream-Status: Pending
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
- compiler-rt/lib/builtins/CMakeLists.txt | 13 ++++++-------
+ compiler-rt/lib/builtins/CMakeLists.txt | 17 ++++++-----------
  compiler-rt/lib/builtins/int_types.h    |  2 +-
- 2 files changed, 7 insertions(+), 8 deletions(-)
+ 2 files changed, 7 insertions(+), 12 deletions(-)
 
 diff --git a/compiler-rt/lib/builtins/CMakeLists.txt b/compiler-rt/lib/builtins/CMakeLists.txt
-index c3dbd65998f1..b3a44ea3c3b3 100644
+index e128fea..eb108d7 100644
 --- a/compiler-rt/lib/builtins/CMakeLists.txt
 +++ b/compiler-rt/lib/builtins/CMakeLists.txt
-@@ -813,11 +813,9 @@ set(mips64el_SOURCES ${GENERIC_TF_SOURCES}
+@@ -916,11 +916,9 @@ set(mips64el_SOURCES ${GENERIC_TF_SOURCES}
  
  set(nvptx64_SOURCES ${GENERIC_SOURCES})
  
@@ -27,7 +27,7 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
    ppc/divtc3.c
    ppc/fixtfdi.c
    ppc/fixunstfdi.c
-@@ -832,14 +830,15 @@ set(powerpc64_SOURCES
+@@ -935,11 +933,11 @@ set(powerpc64_SOURCES
  )
  # These routines require __int128, which isn't supported on AIX.
  if (NOT OS_NAME MATCHES "AIX")
@@ -40,13 +40,23 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
 +    ${powerpc_SOURCES}
    )
  endif()
+ if (OS_NAME MATCHES "AIX")
+@@ -947,12 +945,9 @@ if (OS_NAME MATCHES "AIX")
+     ppc/init_ifuncs.c
+     ${powerpc_SOURCES}
+   )
+-  set(powerpc64_SOURCES
+-    ppc/init_ifuncs.c
+-    ${powerpc64_SOURCES}
+-  )
+ endif()
 -set(powerpc64le_SOURCES ${powerpc64_SOURCES})
 +set(powerpc64le_SOURCES ${powerpc_SOURCES})
 +set(powerpc64_SOURCES ${powerpc_SOURCES})
  
  set(riscv_SOURCES
    cpu_model/riscv.c
-@@ -1014,7 +1013,7 @@ else ()
+@@ -1125,7 +1120,7 @@ else ()
  
        # For RISCV32 and 32-bit SPARC, we must force enable int128 for compiling long
        # double routines.
@@ -56,7 +66,7 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
          list(APPEND BUILTIN_CFLAGS_${arch} -fforce-enable-int128)
        endif()
 diff --git a/compiler-rt/lib/builtins/int_types.h b/compiler-rt/lib/builtins/int_types.h
-index 7c7f8cb64aa9..81386f1b99b0 100644
+index 6411507..754f8ce 100644
 --- a/compiler-rt/lib/builtins/int_types.h
 +++ b/compiler-rt/lib/builtins/int_types.h
 @@ -64,7 +64,7 @@ typedef union {
diff --git a/meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch b/meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
rename to meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
index cccb1e9885..167cd12431 100644
--- a/meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
+++ b/meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
@@ -1,4 +1,4 @@
-From 8c5fc285de0051107aa9b7e2e269aa2667fd16f4 Mon Sep 17 00:00:00 2001
+From f610b9f158e13a40f0e86f7a171be493f8ca64fe Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Fri, 12 Aug 2022 11:50:57 -0700
 Subject: [PATCH] llvm: Do not use cmake infra to detect libzstd
@@ -21,7 +21,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/llvm/lib/Support/CMakeLists.txt b/llvm/lib/Support/CMakeLists.txt
-index 099b0e55579b..8c35b8a31457 100644
+index 1a3fa39..dd11f9a 100644
 --- a/llvm/lib/Support/CMakeLists.txt
 +++ b/llvm/lib/Support/CMakeLists.txt
 @@ -22,7 +22,7 @@ if (HAS_WERROR_GLOBAL_CTORS)
@@ -42,7 +42,7 @@ index 099b0e55579b..8c35b8a31457 100644
  endif()
  
  if( WIN32 )
-@@ -351,7 +351,7 @@ if(LLVM_ENABLE_ZLIB)
+@@ -360,7 +360,7 @@ if(LLVM_ENABLE_ZLIB)
      get_property(zlib_library TARGET ZLIB::ZLIB PROPERTY LOCATION)
    endif()
    get_library_name(${zlib_library} zlib_library)
@@ -51,7 +51,7 @@ index 099b0e55579b..8c35b8a31457 100644
  endif()
  
  if(LLVM_ENABLE_ZSTD)
-@@ -365,7 +365,7 @@ if(LLVM_ENABLE_ZSTD)
+@@ -374,7 +374,7 @@ if(LLVM_ENABLE_ZSTD)
    endif()
    if (zstd_target STREQUAL zstd::libzstd_shared)
      get_library_name(${zstd_library} zstd_library)
diff --git a/meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch b/meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
rename to meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
index a498c36b84..021f622894 100644
--- a/meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
+++ b/meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
@@ -1,4 +1,4 @@
-From 4a114f5fcd2ab8870b26ba3df4747fc066933f66 Mon Sep 17 00:00:00 2001
+From 6917a5e0eb77c0134b59c3cb942292bc5c38e87f Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 3 Jan 2023 18:44:34 -0800
 Subject: [PATCH] compiler-rt: Fix stat struct's size for O32 ABI
@@ -14,7 +14,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 13 insertions(+)
 
 diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
-index 05ebee49f2ab..89c4dcaf3e3d 100644
+index 73eb958..b0dcbde 100644
 --- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
 +++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
 @@ -100,6 +100,18 @@ const unsigned struct_kernel_stat64_sz = 104;
@@ -36,7 +36,7 @@ index 05ebee49f2ab..89c4dcaf3e3d 100644
  const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
                                             ? FIRST_32_SECOND_64(104, 128)
  #      if defined(_ABIN32) && _MIPS_SIM == _ABIN32
-@@ -110,6 +122,7 @@ const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
+@@ -116,6 +128,7 @@ const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
                                             : FIRST_32_SECOND_64(160, 216);
  #      endif
  const unsigned struct_kernel_stat64_sz = 104;
diff --git a/meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch b/meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
similarity index 98%
rename from meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
rename to meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
index 09224af386..19784aef10 100644
--- a/meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
+++ b/meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
@@ -1,4 +1,4 @@
-From 27e4b9755ddd3bec16a851cce0df48e909ae6438 Mon Sep 17 00:00:00 2001
+From 0d7e696f552b1047e89c5114551b6dc902e6f0f1 Mon Sep 17 00:00:00 2001
 From: Martin Jansa <Martin.Jansa@gmail.com>
 Date: Thu, 31 Aug 2023 18:14:47 +0200
 Subject: [PATCH] ToolChains/Gnu.cpp: ARMLibDirs search also in lib32
@@ -55,10 +55,10 @@ Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
  2 files changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index 80fd8058bd98..37cb6cfdf2da 100644
+index 73ff1f4..6a2b362 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2346,7 +2346,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
+@@ -2347,7 +2347,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
    static const char *const AArch64beLibDirs[] = {"/lib"};
    static const char *const AArch64beTriples[] = {"aarch64_be-none-linux-gnu"};
  
@@ -68,10 +68,10 @@ index 80fd8058bd98..37cb6cfdf2da 100644
    static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
                                               "armv7hl-redhat-linux-gnueabi",
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 9fed904c05c2..5bb66c9faa1f 100644
+index 41e0017..5f8b7fd 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -198,6 +198,7 @@ static StringRef getOSLibDir(const llvm::Triple &Triple, const ArgList &Args) {
+@@ -199,6 +199,7 @@ static StringRef getOSLibDir(const llvm::Triple &Triple, const ArgList &Args) {
    // reasoning about oslibdir spellings with the lib dir spellings in the
    // GCCInstallationDetector, but that is a more significant refactoring.
    if (Triple.getArch() == llvm::Triple::x86 || Triple.isPPC32() ||
diff --git a/meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch b/meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
similarity index 60%
rename from meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
rename to meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
index c93a9ec7e0..6577380978 100644
--- a/meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
+++ b/meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
@@ -1,4 +1,4 @@
-From 7023d17f81a472e72a5739e007b9e7148d105137 Mon Sep 17 00:00:00 2001
+From 33988376d79f9eca5f54000cdcc558c8dc3d89ba Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 3 Feb 2024 16:47:10 -0800
 Subject: [PATCH] clang/llvm: Add OE specific ABI triple for N32 ABI
@@ -8,16 +8,17 @@ Its gnun32 when using OE
 Upstream-Status: Inappropriate [OE-Specific]
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 ---
- clang/lib/Driver/ToolChains/Gnu.cpp   | 1 +
- clang/lib/Driver/ToolChains/Linux.cpp | 4 ++--
- llvm/lib/TargetParser/Triple.cpp      | 4 +++-
- 3 files changed, 6 insertions(+), 3 deletions(-)
+ clang/lib/Driver/ToolChains/Gnu.cpp           | 1 +
+ clang/lib/Driver/ToolChains/Linux.cpp         | 4 ++--
+ llvm/include/llvm/TargetParser/TripleName.def | 2 +-
+ llvm/lib/TargetParser/Triple.cpp              | 2 ++
+ 4 files changed, 6 insertions(+), 3 deletions(-)
 
 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index 37cb6cfdf2da..bcd7d345c25a 100644
+index 6a2b362..05d1c44 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2415,6 +2415,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
+@@ -2416,6 +2416,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
  
    static const char *const MIPSN32LibDirs[] = {"/lib32"};
    static const char *const MIPSN32Triples[] = {"mips64-linux-gnuabin32",
@@ -26,10 +27,10 @@ index 37cb6cfdf2da..bcd7d345c25a 100644
    static const char *const MIPSN32ELLibDirs[] = {"/lib32"};
    static const char *const MIPSN32ELTriples[] = {
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 5bb66c9faa1f..c6d6e20dbc4d 100644
+index 5f8b7fd..ac7bd3a 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -138,7 +138,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
+@@ -139,7 +139,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
      return IsMipsR6 ? "mipsisa32r6el-linux-gnu" : "mipsel-linux-gnu";
    case llvm::Triple::mips64: {
      std::string MT = std::string(IsMipsR6 ? "mipsisa64r6" : "mips64") +
@@ -38,7 +39,7 @@ index 5bb66c9faa1f..c6d6e20dbc4d 100644
      if (D.getVFS().exists(concat(SysRoot, "/lib", MT)))
        return MT;
      if (D.getVFS().exists(concat(SysRoot, "/lib/mips64-linux-gnu")))
-@@ -147,7 +147,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
+@@ -148,7 +148,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
    }
    case llvm::Triple::mips64el: {
      std::string MT = std::string(IsMipsR6 ? "mipsisa64r6el" : "mips64el") +
@@ -47,28 +48,32 @@ index 5bb66c9faa1f..c6d6e20dbc4d 100644
      if (D.getVFS().exists(concat(SysRoot, "/lib", MT)))
        return MT;
      if (D.getVFS().exists(concat(SysRoot, "/lib/mips64el-linux-gnu")))
+diff --git a/llvm/include/llvm/TargetParser/TripleName.def b/llvm/include/llvm/TargetParser/TripleName.def
+index bbc03b3..081d8ff 100644
+--- a/llvm/include/llvm/TargetParser/TripleName.def
++++ b/llvm/include/llvm/TargetParser/TripleName.def
+@@ -102,7 +102,7 @@ TRIPLE_OS(H2, "h2")
+ 
+ TRIPLE_ENV(EABIHF, "eabihf")
+ TRIPLE_ENV(EABI, "eabi")
+-TRIPLE_ENV(GNUABIN32, "gnuabin32")
++TRIPLE_ENV(GNUABIN32, "gnun32")
+ TRIPLE_ENV(GNUABI64, "gnuabi64")
+ TRIPLE_ENV(GNUEABIHFT64, "gnueabihft64")
+ TRIPLE_ENV(GNUEABIHF, "gnueabihf")
 diff --git a/llvm/lib/TargetParser/Triple.cpp b/llvm/lib/TargetParser/Triple.cpp
-index 86b74451ec0d..d94b7d44d11a 100644
+index 883e654..aa2bb35 100644
 --- a/llvm/lib/TargetParser/Triple.cpp
 +++ b/llvm/lib/TargetParser/Triple.cpp
-@@ -358,7 +358,7 @@ StringRef Triple::getEnvironmentTypeName(EnvironmentType Kind) {
-   case GNU: return "gnu";
-   case GNUT64: return "gnut64";
-   case GNUABI64: return "gnuabi64";
--  case GNUABIN32: return "gnuabin32";
-+  case GNUABIN32: return "gnun32";
-   case GNUEABI: return "gnueabi";
-   case GNUEABIT64: return "gnueabit64";
-   case GNUEABIHF: return "gnueabihf";
-@@ -762,6 +762,7 @@ static Triple::EnvironmentType parseEnvironment(StringRef EnvironmentName) {
-       .StartsWith("eabihf", Triple::EABIHF)
-       .StartsWith("eabi", Triple::EABI)
-       .StartsWith("gnuabin32", Triple::GNUABIN32)
-+      .StartsWith("gnun32", Triple::GNUABIN32)
-       .StartsWith("gnuabi64", Triple::GNUABI64)
-       .StartsWith("gnueabihft64", Triple::GNUEABIHFT64)
-       .StartsWith("gnueabihf", Triple::GNUEABIHF)
-@@ -1087,6 +1088,7 @@ Triple::Triple(std::string &&Str) : Data(std::move(Str)) {
+@@ -755,6 +755,7 @@ static Triple::OSType parseOS(StringRef OSName) {
+ 
+ static Triple::EnvironmentType parseEnvironment(StringRef EnvironmentName) {
+   return StringSwitch<Triple::EnvironmentType>(EnvironmentName)
++      .StartsWith("gnuabin32", Triple::GNUABIN32)
+ #define TRIPLE_ENV(Enum, Name) .StartsWith(Name, Triple::Enum)
+ #include "llvm/TargetParser/TripleName.def"
+       .Default(Triple::UnknownEnvironment);
+@@ -1106,6 +1107,7 @@ Triple::Triple(std::string &&Str) : Data(std::move(Str)) {
        Environment =
            StringSwitch<Triple::EnvironmentType>(Components[0])
                .StartsWith("mipsn32", Triple::GNUABIN32)
diff --git a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch b/meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
similarity index 84%
rename from meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
rename to meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
index 72ffdc6c1f..34ba534074 100644
--- a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
+++ b/meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
@@ -1,4 +1,4 @@
-From 17a1a4919c0ff554fc30bbb85a63b9d2a1164324 Mon Sep 17 00:00:00 2001
+From 9ec97845821ead65ebd8ab26b69d949e10b65338 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 14 May 2024 22:04:43 -0700
 Subject: [PATCH] llvm: Add libunwind.pc.in and llvm-config scripts
@@ -10,15 +10,15 @@ Upstream-Status: Inappropriate [ OE-Specific ]
 Signed-off-by: Khem Raj <raj.khem@gmail.com>
 Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
 ---
- libunwind/libunwind.pc.in          |  9 ++++++
- llvm/tools/llvm-config/llvm-config | 52 ++++++++++++++++++++++++++++++
- 2 files changed, 61 insertions(+)
+ libunwind/libunwind.pc.in          |  9 +++++++++
+ llvm/tools/llvm-config/llvm-config | 15 +++++++++++++++
+ 2 files changed, 24 insertions(+)
  create mode 100644 libunwind/libunwind.pc.in
  create mode 100644 llvm/tools/llvm-config/llvm-config
 
 diff --git a/libunwind/libunwind.pc.in b/libunwind/libunwind.pc.in
 new file mode 100644
-index 000000000000..a93d676604f9
+index 0000000..a93d676
 --- /dev/null
 +++ b/libunwind/libunwind.pc.in
 @@ -0,0 +1,9 @@
@@ -33,7 +33,7 @@ index 000000000000..a93d676604f9
 +Libs: -lunwind
 diff --git a/llvm/tools/llvm-config/llvm-config b/llvm/tools/llvm-config/llvm-config
 new file mode 100644
-index 000000000000..6a0dd54b8eab
+index 0000000..0578773
 --- /dev/null
 +++ b/llvm/tools/llvm-config/llvm-config
 @@ -0,0 +1,15 @@
diff --git a/meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch b/meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
similarity index 90%
rename from meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
rename to meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
index 934d5adc50..55ad603b7c 100644
--- a/meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
+++ b/meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
@@ -1,7 +1,8 @@
-From a2171be64a181e0b263fc8ec31a760193651203c Mon Sep 17 00:00:00 2001
+From b9565c7e6525f3ca20df3171c36698b521a45594 Mon Sep 17 00:00:00 2001
 From: Martin Jansa <martin.jansa@gmail.com>
 Date: Fri, 13 Sep 2024 13:38:08 +0200
-Subject: [PATCH] scan-build-py: respect LLVM_LIBDIR_SUFFIX like other tools do
+Subject: [PATCH] scan-build-py: respect LLVM_LIBDIR_SUFFIX like other
+ tools do
 
 * other libraries are installed in 'lib64' or 'lib32' based on
   LLVM_LIBDIR_SUFFIX value, but libscanbuild files were always
@@ -11,13 +12,13 @@ Upstream-Status: Submitted [https://github.com/llvm/llvm-project/pull/108549]
 
 Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
 ---
- clang/tools/scan-build-py/CMakeLists.txt | 26 ++++++++++++------------
- 1 file changed, 13 insertions(+), 13 deletions(-)
+ clang/tools/scan-build-py/CMakeLists.txt | 32 ++++++++++++------------
+ 1 file changed, 16 insertions(+), 16 deletions(-)
 
-Index: llvm-project-22.1.2.src/clang/tools/scan-build-py/CMakeLists.txt
-===================================================================
---- llvm-project-22.1.2.src.orig/clang/tools/scan-build-py/CMakeLists.txt
-+++ llvm-project-22.1.2.src/clang/tools/scan-build-py/CMakeLists.txt
+diff --git a/clang/tools/scan-build-py/CMakeLists.txt b/clang/tools/scan-build-py/CMakeLists.txt
+index 84087a9..9647642 100644
+--- a/clang/tools/scan-build-py/CMakeLists.txt
++++ b/clang/tools/scan-build-py/CMakeLists.txt
 @@ -80,52 +80,52 @@ if(CLANG_INSTALL_SCANBUILDPY)
    endforeach()
  
diff --git a/meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch b/meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
rename to meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
index fe24fe051b..b3fb642742 100644
--- a/meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
+++ b/meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
@@ -1,4 +1,4 @@
-From 6b1f360c66b60c4bb639057590a8b2162d3bcf6b Mon Sep 17 00:00:00 2001
+From f68925e7c31fa4bdd684a4ab44fd1350bb43205b Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 13 Mar 2025 00:30:38 -0700
 Subject: [PATCH] compiler-rt: Do not pass --target to clang compiler
@@ -13,7 +13,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 4 deletions(-)
 
 diff --git a/compiler-rt/lib/fuzzer/CMakeLists.txt b/compiler-rt/lib/fuzzer/CMakeLists.txt
-index a57e2fe46245..2928ed2ab6d5 100644
+index 2da488d..9af4410 100644
 --- a/compiler-rt/lib/fuzzer/CMakeLists.txt
 +++ b/compiler-rt/lib/fuzzer/CMakeLists.txt
 @@ -140,10 +140,6 @@ if(OS_NAME MATCHES "Android|Linux|Fuchsia" AND
diff --git a/meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch b/meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
similarity index 92%
rename from meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
rename to meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
index 413bc3f275..28d0567e15 100644
--- a/meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
+++ b/meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
@@ -1,4 +1,4 @@
-From 281cd05306cbfa5744e4a1f3ebf5c745324efe7a Mon Sep 17 00:00:00 2001
+From bf8a65efcdce65143081785b9ed8759d60be1bd4 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com>
 Date: Fri, 27 Nov 2020 10:11:08 +0000
 Subject: [PATCH] AsmMatcherEmitter: sort ClassInfo lists by name as well
@@ -14,7 +14,7 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
  1 file changed, 4 insertions(+), 1 deletion(-)
 
 diff --git a/llvm/utils/TableGen/AsmMatcherEmitter.cpp b/llvm/utils/TableGen/AsmMatcherEmitter.cpp
-index e6085af5aa91..b0180638c754 100644
+index 4af5c85..917aeec 100644
 --- a/llvm/utils/TableGen/AsmMatcherEmitter.cpp
 +++ b/llvm/utils/TableGen/AsmMatcherEmitter.cpp
 @@ -384,7 +384,10 @@ public:
diff --git a/meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch b/meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
similarity index 92%
rename from meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
rename to meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
index e059748873..7724af8009 100644
--- a/meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
+++ b/meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
@@ -1,4 +1,4 @@
-From cbc2595eed96fa7de77162e4c7b99681579d01ef Mon Sep 17 00:00:00 2001
+From f58186cc6ba2fff4d2e9fb624a904b1c5a4f7733 Mon Sep 17 00:00:00 2001
 From: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
 Date: Wed, 2 Apr 2025 17:05:17 +0300
 Subject: [PATCH] llvm-config: remove LLVM_LDFLAGS from --ldflags output
@@ -18,7 +18,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/llvm/tools/llvm-config/llvm-config.cpp b/llvm/tools/llvm-config/llvm-config.cpp
-index 0a3f51ae2b83..5c95a1f3ff24 100644
+index 64795e9..3e57005 100644
 --- a/llvm/tools/llvm-config/llvm-config.cpp
 +++ b/llvm/tools/llvm-config/llvm-config.cpp
 @@ -576,7 +576,7 @@ int main(int argc, char **argv) {
diff --git a/meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch b/meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
similarity index 95%
rename from meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
rename to meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
index 52bdeaf9d5..a1847f99f9 100644
--- a/meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
+++ b/meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
@@ -1,4 +1,4 @@
-From 3a486a17b697c65cdc7d2c17d9e14f2bfc2be911 Mon Sep 17 00:00:00 2001
+From 9046478db7833765487e66d5a3706b7cb67f1ee2 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sat, 10 May 2025 14:03:12 -0700
 Subject: [PATCH] compiler-rt: Exclude sync_fetch_and_* for any pre-ARMv6
@@ -40,10 +40,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 12 insertions(+)
 
 diff --git a/compiler-rt/lib/builtins/CMakeLists.txt b/compiler-rt/lib/builtins/CMakeLists.txt
-index b3a44ea3c3b3..4a328ab0ca26 100644
+index eb108d7..4041119 100644
 --- a/compiler-rt/lib/builtins/CMakeLists.txt
 +++ b/compiler-rt/lib/builtins/CMakeLists.txt
-@@ -975,6 +975,18 @@ else ()
+@@ -1082,6 +1082,18 @@ else ()
          ${TARGET_${arch}_CFLAGS})
        list(JOIN CMAKE_REQUIRED_FLAGS " " CMAKE_REQUIRED_FLAGS)
        message(STATUS "Performing additional configure checks with target flags: ${CMAKE_REQUIRED_FLAGS}")
diff --git a/meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch b/meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
rename to meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
index b0aae5457a..d3a9a6c308 100644
--- a/meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
+++ b/meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
@@ -1,7 +1,7 @@
-From b71c398a1b10b29886c2db2a920f476fec6f7de2 Mon Sep 17 00:00:00 2001
+From aab77dfb9c2e1a118ffb5bd690f34bf93b6f3f36 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Thu, 22 May 2025 21:50:45 -0700
-Subject: [PATCH] [compiler-rt] Hardcode uptr/sptr typedefs on Mips/Linux
+Subject: [PATCH] Hardcode uptr/sptr typedefs on Mips/Linux
 
 Sanitizer build on Mips/Linux faills to build due to assertion errors
 mismatched definitions. This is due to inconsistent definitions of
@@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h b/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
-index c719e2a8ef60..60b997e653c4 100644
+index c694897..08f6d35 100644
 --- a/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
 +++ b/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
-@@ -139,7 +139,7 @@
+@@ -143,7 +143,7 @@
  namespace __sanitizer {
  
  #if defined(__UINTPTR_TYPE__)
diff --git a/meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch b/meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
similarity index 89%
rename from meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
rename to meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
index 57003dcf56..faae71645a 100644
--- a/meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
+++ b/meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
@@ -1,4 +1,4 @@
-From 9ace97c0c2df52d823c9d5345cca0251bf2ccf16 Mon Sep 17 00:00:00 2001
+From cffcea54bf4605d958407edb233fffdbe730f4af Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Sun, 27 Jul 2025 19:12:13 -0700
 Subject: [PATCH] Revert "[libc++] Remap headers in the debug info when
@@ -19,10 +19,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 5 deletions(-)
 
 diff --git a/libcxx/include/CMakeLists.txt b/libcxx/include/CMakeLists.txt
-index 787cfffa5019..d73bcd852a1e 100644
+index b40f586..7bd7622 100644
 --- a/libcxx/include/CMakeLists.txt
 +++ b/libcxx/include/CMakeLists.txt
-@@ -1718,11 +1718,6 @@ add_dependencies(cxx-headers generate-cxx-headers)
+@@ -1728,11 +1728,6 @@ add_dependencies(cxx-headers generate-cxx-headers)
  target_include_directories(cxx-headers INTERFACE ${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}
                                                   ${LIBCXX_GENERATED_INCLUDE_DIR})
  
diff --git a/meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch b/meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
rename to meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
index 0cdb2ad668..af9564053c 100644
--- a/meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
+++ b/meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
@@ -1,4 +1,4 @@
-From 53da129f7986c5bd310f4f4a8236987df7e073c6 Mon Sep 17 00:00:00 2001
+From b6a9ddd0ba2d8bd14871c135157f3878a9d629c1 Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@arm.com>
 Date: Mon, 29 Sep 2025 14:44:05 +0100
 Subject: [PATCH] Don't expose LLVM_HAVE_OPT_VIEWER_MODULES externally
@@ -14,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 1 deletion(-)
 
 diff --git a/llvm/cmake/modules/LLVMConfig.cmake.in b/llvm/cmake/modules/LLVMConfig.cmake.in
-index 70c807abea98..5603c9215332 100644
+index 6f5fcc6..ce07563 100644
 --- a/llvm/cmake/modules/LLVMConfig.cmake.in
 +++ b/llvm/cmake/modules/LLVMConfig.cmake.in
-@@ -137,7 +137,6 @@ set(LLVM_DEFINITIONS "@LLVM_DEFINITIONS@")
+@@ -145,7 +145,6 @@ set(LLVM_DEFINITIONS "@LLVM_DEFINITIONS@")
  set(LLVM_BINARY_DIR "@LLVM_CONFIG_BINARY_DIR@")
  set(LLVM_CMAKE_DIR "@LLVM_CONFIG_CMAKE_DIR@")
  set(LLVM_TOOLS_BINARY_DIR "@LLVM_CONFIG_TOOLS_BINARY_DIR@")
diff --git a/meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch b/meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
similarity index 81%
rename from meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
rename to meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
index 5efe043eaf..690791c5e3 100644
--- a/meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
+++ b/meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
@@ -1,7 +1,7 @@
-From de58b9bbc8c52299ff22c4f0ab21e3878d411669 Mon Sep 17 00:00:00 2001
+From a55e7674203ffcb42e4e3ee4c8cf7aa964aee086 Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@arm.com>
 Date: Sat, 11 Oct 2025 16:01:50 -0700
-Subject: [PATCH] [clang] Only build clang-tblgen if it is actually needed
+Subject: [PATCH] Only build clang-tblgen if it is actually needed
 
 It's possible to build clang with an existing clang-tblgen (common when
 cross-compiling, for instance) by setting CLANG_TABLEGEN_EXE.  If this
@@ -16,10 +16,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 3 insertions(+), 1 deletion(-)
 
 diff --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt
-index e4cb1a359620..b650b3b986f4 100644
+index 89f584c..bd7ebc3 100644
 --- a/clang/CMakeLists.txt
 +++ b/clang/CMakeLists.txt
-@@ -479,7 +479,9 @@ option(CLANG_ENABLE_HLSL "Include HLSL build products" Off)
+@@ -531,7 +531,9 @@ option(CLANG_ENABLE_HLSL "Include HLSL build products" Off)
  # While HLSL support is experimental this should stay hidden.
  mark_as_advanced(CLANG_ENABLE_HLSL)
  
diff --git a/meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch b/meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
similarity index 93%
rename from meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
rename to meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
index 583e91e497..6081f2d7b4 100644
--- a/meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
+++ b/meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
@@ -1,4 +1,4 @@
-From bca77d818187e68989dfa9e386b38632b76a477e Mon Sep 17 00:00:00 2001
+From b383508d002bb41ac979ab356f73fcf0ae97ca00 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com>
 Date: Tue, 28 Oct 2025 15:44:49 -0700
 Subject: [PATCH] llvm-libgcc: Fix symlink path for libcc when
@@ -33,10 +33,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
  1 file changed, 13 insertions(+), 3 deletions(-)
 
 diff --git a/llvm-libgcc/CMakeLists.txt b/llvm-libgcc/CMakeLists.txt
-index 47208fc19869..54009c1104c3 100644
+index a297447..1ae9167 100644
 --- a/llvm-libgcc/CMakeLists.txt
 +++ b/llvm-libgcc/CMakeLists.txt
-@@ -124,11 +124,21 @@ target_link_libraries(unwind_shared PUBLIC
+@@ -133,11 +133,21 @@ target_link_libraries(unwind_shared PUBLIC
  #===============================================================================
  
  get_compiler_rt_install_dir(${COMPILER_RT_DEFAULT_TARGET_ARCH} install_dir_builtins)
@@ -60,7 +60,7 @@ index 47208fc19869..54009c1104c3 100644
    string(PREPEND install_dir_builtins "../")
  endif()
  set(LLVM_LIBGCC_COMPILER_RT ${install_dir_builtins}/libclang_rt.builtins${builtins_suffix}.a)
-@@ -137,7 +147,7 @@ add_custom_target(llvm-libgcc ALL
+@@ -146,7 +156,7 @@ add_custom_target(llvm-libgcc ALL
    DEPENDS unwind_shared unwind_static clang_rt.builtins-${COMPILER_RT_DEFAULT_TARGET_ARCH}
    COMMAND ${CMAKE_COMMAND} -E create_symlink ${LLVM_LIBGCC_COMPILER_RT} libgcc.a
    COMMAND ${CMAKE_COMMAND} -E create_symlink libunwind.a libgcc_eh.a
diff --git a/meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch b/meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
rename to meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
index a2a7fa80f1..ecaaa738a7 100644
--- a/meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
+++ b/meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
@@ -1,7 +1,8 @@
-From b818a92ac171e80e39ad9e99d1f862d23f2bb5b3 Mon Sep 17 00:00:00 2001
+From 7da49a0e48fa77d38548f8f1dedc7cb1bb8dce53 Mon Sep 17 00:00:00 2001
 From: "mark.yang" <mark.yang@lge.com>
 Date: Tue, 14 Apr 2026 16:17:01 +0900
-Subject: [PATCH] Consolidate and fix sysroot-based compiler-rt search paths
+Subject: [PATCH] Consolidate and fix sysroot-based compiler-rt search
+ paths
 
 Consolidate patches 0008 and 0033 into a single patch with a fix for
 native builds.
@@ -41,10 +42,10 @@ Signed-off-by: mark.yang <mark.yang@lge.com>
  1 file changed, 28 insertions(+), 3 deletions(-)
 
 diff --git a/clang/lib/Driver/ToolChain.cpp b/clang/lib/Driver/ToolChain.cpp
-index 77a2c73f0..ac28b51c4 100644
+index f894a06..eceada5 100644
 --- a/clang/lib/Driver/ToolChain.cpp
 +++ b/clang/lib/Driver/ToolChain.cpp
-@@ -15,6 +15,7 @@
+@@ -16,6 +16,7 @@
  #include "ToolChains/InterfaceStubs.h"
  #include "clang/Basic/ObjCRuntime.h"
  #include "clang/Basic/Sanitizers.h"
@@ -52,7 +53,7 @@ index 77a2c73f0..ac28b51c4 100644
  #include "clang/Config/config.h"
  #include "clang/Driver/Action.h"
  #include "clang/Driver/CommonArgs.h"
-@@ -723,7 +724,15 @@ StringRef ToolChain::getOSLibName() const {
+@@ -872,7 +873,15 @@ StringRef ToolChain::getOSLibName() const {
  }
  
  std::string ToolChain::getCompilerRTPath() const {
@@ -69,7 +70,7 @@ index 77a2c73f0..ac28b51c4 100644
    if (isBareMetal()) {
      llvm::sys::path::append(Path, "lib", getOSLibName());
      if (!SelectedMultilibs.empty()) {
-@@ -1021,7 +1030,15 @@ ToolChain::getTargetSubDirPath(StringRef BaseDir) const {
+@@ -1179,7 +1188,15 @@ std::optional<std::string> ToolChain::getDefaultIntrinsicModuleDir() const {
  }
  
  std::optional<std::string> ToolChain::getRuntimePath() const {
@@ -86,7 +87,7 @@ index 77a2c73f0..ac28b51c4 100644
    llvm::sys::path::append(P, "lib");
    if (auto Ret = getTargetSubDirPath(P))
      return Ret;
-@@ -1049,7 +1066,15 @@ ToolChain::path_list ToolChain::getArchSpecificLibPaths() const {
+@@ -1207,7 +1224,15 @@ ToolChain::path_list ToolChain::getArchSpecificLibPaths() const {
    path_list Paths;
  
    auto AddPath = [&](const ArrayRef<StringRef> &SS) {
diff --git a/meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch b/meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
similarity index 83%
rename from meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch
rename to meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
index 9b4e29ff64..5e53d43944 100644
--- a/meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch
+++ b/meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
@@ -1,3 +1,8 @@
+From 9463b5d24fc62372fc2731d4d4665c64c72b55b2 Mon Sep 17 00:00:00 2001
+From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
+Date: Wed, 19 Aug 2026 22:46:10 +0530
+Subject: [PATCH] guard clang-tools-extra test
+
 clang-tools-extra tests depend on the llvm-bcanalyzer CMake target, which
 exists in LLVM's CMake project but is not visible when Clang is built
 separately. To run clang tests, disable clang-tools-extra tests for now.
@@ -22,30 +27,49 @@ Without this patch when CLANG_INCLUDE_TESTS is ON got the following error
 -------------------------------------------------------------------------------
 
 Upstream-Status: Inappropriate [OE-Specific]
+
 Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
+---
+ clang-tools-extra/CMakeLists.txt                 | 4 ++--
+ clang-tools-extra/clangd/CMakeLists.txt          | 2 +-
+ clang-tools-extra/include-cleaner/CMakeLists.txt | 2 +-
+ 3 files changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/clang-tools-extra/CMakeLists.txt b/clang-tools-extra/CMakeLists.txt
-index 6b6f2b1..26e4c10 100644
+index 87050db..3824129 100644
 --- a/clang-tools-extra/CMakeLists.txt
 +++ b/clang-tools-extra/CMakeLists.txt
-@@ -8,7 +8,7 @@ include(GNUInstallDirs)
+@@ -8,7 +8,7 @@ option(CLANG_TIDY_ENABLE_STATIC_ANALYZER
  option(CLANG_TIDY_ENABLE_QUERY_BASED_CUSTOM_CHECKS
    "Enable query-based custom checks in clang-tidy" ON)
-
+ 
 -if(CLANG_INCLUDE_TESTS)
 +if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
    umbrella_lit_testsuite_begin(check-clang-tools)
-
+ 
    option(CLANG_TOOLS_TEST_USE_VG "Run Clang tools' tests under Valgrind" OFF)
 @@ -45,7 +45,7 @@ if (CLANG_ENABLE_CLANGD)
  endif()
-
+ 
  # Add the common testsuite after all the tools.
 -if(CLANG_INCLUDE_TESTS)
 +if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
    add_subdirectory(test)
    add_subdirectory(unittests)
    umbrella_lit_testsuite_end(check-clang-tools)
+diff --git a/clang-tools-extra/clangd/CMakeLists.txt b/clang-tools-extra/clangd/CMakeLists.txt
+index 890562d..c4d6623 100644
+--- a/clang-tools-extra/clangd/CMakeLists.txt
++++ b/clang-tools-extra/clangd/CMakeLists.txt
+@@ -217,7 +217,7 @@ endif()
+ option(CLANGD_BUILD_DEXP "Build the dexp tool as part of Clangd" ON)
+ llvm_canonicalize_cmake_booleans(CLANGD_BUILD_DEXP)
+ 
+-if(CLANG_INCLUDE_TESTS)
++if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
+   add_subdirectory(test)
+   add_subdirectory(unittests)
+ endif()
 diff --git a/clang-tools-extra/include-cleaner/CMakeLists.txt b/clang-tools-extra/include-cleaner/CMakeLists.txt
 index dc147f9..4855577 100644
 --- a/clang-tools-extra/include-cleaner/CMakeLists.txt
@@ -59,16 +83,3 @@ index dc147f9..4855577 100644
    add_subdirectory(test)
    add_subdirectory(unittests)
  endif()
-diff --git a/clang-tools-extra/clangd/CMakeLists.txt b/clang-tools-extra/clangd/CMakeLists.txt
-index a1e9da4..94dcb96 100644
---- a/clang-tools-extra/clangd/CMakeLists.txt
-+++ b/clang-tools-extra/clangd/CMakeLists.txt
-@@ -215,7 +215,7 @@ endif()
- option(CLANGD_BUILD_DEXP "Build the dexp tool as part of Clangd" ON)
- llvm_canonicalize_cmake_booleans(CLANGD_BUILD_DEXP)
-
--if(CLANG_INCLUDE_TESTS)
-+if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
-   add_subdirectory(test)
-   add_subdirectory(unittests)
- endif()
diff --git a/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch b/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
deleted file mode 100644
index 6021f736ff..0000000000
--- a/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 051b3bfa1e0e5cfed4a02318e330b38b0090cc49 Mon Sep 17 00:00:00 2001
-From: Serge Pavlov <sepavloff@gmail.com>
-Date: Fri, 25 Jul 2025 13:35:19 +0700
-Subject: [PATCH] Prevent revisiting block when searching for noreturn vars
-
-When searching for noreturn variable initializations, do not visit CFG
-blocks that are already visited, it prevents hanging  the analysis.
-
-It must fix https://github.com/llvm/llvm-project/issues/150336.
-
-Upstream-Status: Submitted [https://github.com/llvm/llvm-project/pull/150582]
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- clang/test/SemaCXX/noreturn-vars.cpp | 17 +++++++++++++++++
- 1 file changed, 17 insertions(+)
-
-diff --git a/clang/test/SemaCXX/noreturn-vars.cpp b/clang/test/SemaCXX/noreturn-vars.cpp
-index ca65fcf5ca31..1bf074149f04 100644
---- a/clang/test/SemaCXX/noreturn-vars.cpp
-+++ b/clang/test/SemaCXX/noreturn-vars.cpp
-@@ -225,3 +225,20 @@ extern void abc_02(func_type *);
-   abc_02(&func_ptr);
-   func_ptr();
- } // expected-warning {{function declared 'noreturn' should not return}}
-+
-+namespace Issue150336 {
-+void free(void *);
-+typedef void (*sel_freefunc)(void *);
-+struct gmx_ana_selmethod_t {
-+  sel_freefunc free;
-+  int nparams;
-+  int *param;
-+};
-+void gmx_selelem_free_method(struct gmx_ana_selmethod_t* method, void* mdata) {
-+    sel_freefunc free_func = 0;
-+    for (int i = 0; i < method->nparams; ++i)
-+        free(&method->param[i]);
-+    if (mdata && free_func)
-+        free_func(mdata);
-+}
-+}
diff --git a/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch b/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
new file mode 100644
index 0000000000..df35636055
--- /dev/null
+++ b/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
@@ -0,0 +1,36 @@
+From: Sunil Dora <sunilkumar.dora@windriver.com>
+Date: Fri, 29 Aug 2026 13:55:00 +0530
+Subject: [PATCH] libc: Disable float16 on 32-bit x86 without SSE2
+
+GCC 16 defines __FLT16_MANT_DIG__ when targeting i686 even though
+_Float16 is only usable on x86-32 with SSE2 enabled. The float16
+detection in float16-macros.h keys on that macro, so the shared f16
+math headers are compiled on plain i686 and every use of _Float16
+fails:
+
+  libc/src/__support/FPUtil/BasicOperations.h:63:67:
+      error: SSE register return with SSE2 disabled
+  libc/src/__support/math/acosf16.h:73:14:
+      error: invalid conversion from type '_Float16' without option '-msse2'
+
+Since llvm/lib/Support/APFloat.cpp started including shared/math.h,
+this breaks the LLVM build itself for 32-bit x86 baselines older than
+SSE2 (e.g. -march=pentiumpro), as used by Yocto/OpenEmbedded multilib.
+
+Require SSE2 on 32-bit x86 in the guard, matching the existing
+exclusions for 32-bit Arm and RISC-V. Targets with SSE2 are unaffected.
+
+Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/05da143c63d333420b99eab198e1a89c97480929]
+Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
+---
+--- a/libc/include/llvm-libc-macros/float16-macros.h	2026-08-29 13:55:04.771442947 +0530
++++ b/libc/include/llvm-libc-macros/float16-macros.h	2026-08-29 13:55:04.773991812 +0530
+@@ -15,7 +15,7 @@
+     (!defined(__GNUC__) || __GNUC__ >= 13 ||                                   \
+      (defined(__clang__) && __clang_major__ >= 12)) &&                         \
+     !defined(__arm__) && !defined(_M_ARM) && !defined(__riscv) &&              \
+-    !defined(_WIN32)
++    !defined(_WIN32) && (!defined(__i386__) || defined(__SSE2__))
+ #define LIBC_TYPES_HAS_FLOAT16
+ 
+ // TODO: This would no longer be required if HdrGen let us guard function
diff --git a/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch b/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
deleted file mode 100644
index 493948acef..0000000000
--- a/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
+++ /dev/null
@@ -1,274 +0,0 @@
-From 82f18b02d9fec1bcc225a92251466ffee82f56b5 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 20 Mar 2026 14:22:17 -0700
-Subject: [PATCH] [Clang] Rename UNUSED and UNKNOWN elements of OffloadArch enum to avoid 
- macro collisions
-
-OffloadArch uses enumerator named `UNUSED` `UNKNOWN`, which are common macro name
-in external codebases (e.g. Mesa defines UNUSED as an attribute helper). If such
-a macro is visible when including clang/Basic/OffloadArch.h, the preprocessor
-expands the token inside the enum and breaks compilation of the installed Clang
-headers.
-
-Rename the enumerator to `Unused` and `Unknown` and update all in-tree references. This is a
-spelling-only change (no behavioral impact) and mirrors the existing approach
-used for SM_32_ to avoid macro clashes.
-
-Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/5bc3d1966b2d0b300c338d85bb38e356f0d12a8c]
-Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
-
-diff --git a/clang/include/clang/Basic/OffloadArch.h b/clang/include/clang/Basic/OffloadArch.h
-index ea665b1..970487c 100644
---- a/clang/include/clang/Basic/OffloadArch.h
-+++ b/clang/include/clang/Basic/OffloadArch.h
-@@ -16,8 +16,8 @@ class StringRef;
- namespace clang {
-
- enum class OffloadArch {
--  UNUSED,
--  UNKNOWN,
-+  Unused,
-+  Unknown,
-   // TODO: Deprecate and remove GPU architectures older than sm_52.
-   SM_20,
-   SM_21,
-@@ -145,7 +145,7 @@ const char *OffloadArchToString(OffloadArch A);
- const char *OffloadArchToVirtualArchString(OffloadArch A);
-
- // Convert a string to an OffloadArch enum value. Returns
--// OffloadArch::UNKNOWN if the string is not recognized.
-+// OffloadArch::Unknown if the string is not recognized.
- OffloadArch StringToOffloadArch(llvm::StringRef S);
-
- } // namespace clang
-diff --git a/clang/lib/Basic/Cuda.cpp b/clang/lib/Basic/Cuda.cpp
-index 514fa2f..7884910 100644
---- a/clang/lib/Basic/Cuda.cpp
-+++ b/clang/lib/Basic/Cuda.cpp
-@@ -75,7 +75,7 @@ CudaVersion ToCudaVersion(llvm::VersionTuple Version) {
- }
-
- CudaVersion MinVersionForOffloadArch(OffloadArch A) {
--  if (A == OffloadArch::UNKNOWN)
-+  if (A == OffloadArch::Unknown)
-     return CudaVersion::UNKNOWN;
-
-   // AMD GPUs do not depend on CUDA versions.
-@@ -141,7 +141,7 @@ CudaVersion MaxVersionForOffloadArch(OffloadArch A) {
-     return CudaVersion::NEW;
-
-   switch (A) {
--  case OffloadArch::UNKNOWN:
-+  case OffloadArch::Unknown:
-     return CudaVersion::UNKNOWN;
-   case OffloadArch::SM_20:
-   case OffloadArch::SM_21:
-diff --git a/clang/lib/Basic/OffloadArch.cpp b/clang/lib/Basic/OffloadArch.cpp
-index 05177f1..f3bbe64 100644
---- a/clang/lib/Basic/OffloadArch.cpp
-+++ b/clang/lib/Basic/OffloadArch.cpp
-@@ -17,7 +17,7 @@ struct OffloadArchToStringMap {
- #define GFX(gpu) {OffloadArch::GFX##gpu, "gfx" #gpu, "compute_amdgcn"}
- static const OffloadArchToStringMap ArchNames[] = {
-     // clang-format off
--    {OffloadArch::UNUSED, "", ""},
-+    {OffloadArch::Unused, "", ""},
-     SM(20), {OffloadArch::SM_21, "sm_21", "compute_20"}, // Fermi
-     SM(30), {OffloadArch::SM_32_, "sm_32", "compute_32"}, SM(35), SM(37),  // Kepler
-     SM(50), SM(52), SM(53),          // Maxwell
-@@ -132,7 +132,7 @@ OffloadArch StringToOffloadArch(llvm::StringRef S) {
-         return S == Map.ArchName;
-       });
-   if (Result == std::end(ArchNames))
--    return OffloadArch::UNKNOWN;
-+    return OffloadArch::Unknown;
-   return Result->Arch;
- }
-
-diff --git a/clang/lib/Basic/Targets/NVPTX.cpp b/clang/lib/Basic/Targets/NVPTX.cpp
-index 6526eef..9584f8a 100644
---- a/clang/lib/Basic/Targets/NVPTX.cpp
-+++ b/clang/lib/Basic/Targets/NVPTX.cpp
-@@ -64,7 +64,7 @@ NVPTXTargetInfo::NVPTXTargetInfo(const llvm::Triple &Triple,
-   // Define available target features
-   // These must be defined in sorted order!
-   NoAsmVariants = true;
--  GPU = OffloadArch::UNUSED;
-+  GPU = OffloadArch::Unused;
-
-   // PTX supports f16 as a fundamental type.
-   HasFastHalfType = true;
-diff --git a/clang/lib/Basic/Targets/NVPTX.h b/clang/lib/Basic/Targets/NVPTX.h
-index 9bd0cc3..eeffb0e 100644
---- a/clang/lib/Basic/Targets/NVPTX.h
-+++ b/clang/lib/Basic/Targets/NVPTX.h
-@@ -87,7 +87,7 @@ public:
-   initFeatureMap(llvm::StringMap<bool> &Features, DiagnosticsEngine &Diags,
-                  StringRef CPU,
-                  const std::vector<std::string> &FeaturesVec) const override {
--    if (GPU != OffloadArch::UNUSED)
-+    if (GPU != OffloadArch::Unused)
-       Features[OffloadArchToString(GPU)] = true;
-     // Only add PTX feature if explicitly requested. Otherwise, let the backend
-     // use the minimum required PTX version for the target SM.
-@@ -146,7 +146,7 @@ public:
-   }
-
-   bool isValidCPUName(StringRef Name) const override {
--    return StringToOffloadArch(Name) != OffloadArch::UNKNOWN;
-+    return StringToOffloadArch(Name) != OffloadArch::Unknown;
-   }
-
-   void fillValidCPUList(SmallVectorImpl<StringRef> &Values) const override {
-@@ -157,7 +157,7 @@ public:
-
-   bool setCPU(const std::string &Name) override {
-     GPU = StringToOffloadArch(Name);
--    return GPU != OffloadArch::UNKNOWN;
-+    return GPU != OffloadArch::Unknown;
-   }
-
-   void setSupportedOpenCLOpts() override {
-diff --git a/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp b/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
-index db0d56d..f78047d 100644
---- a/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
-+++ b/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
-@@ -2266,15 +2266,15 @@ bool CGOpenMPRuntimeGPU::hasAllocateAttributeForGlobalVar(const VarDecl *VD,
- // Get current OffloadArch and ignore any unknown values
- static OffloadArch getOffloadArch(CodeGenModule &CGM) {
-   if (!CGM.getTarget().hasFeature("ptx"))
--    return OffloadArch::UNKNOWN;
-+    return OffloadArch::Unknown;
-   for (const auto &Feature : CGM.getTarget().getTargetOpts().FeatureMap) {
-     if (Feature.getValue()) {
-       OffloadArch Arch = StringToOffloadArch(Feature.getKey());
--      if (Arch != OffloadArch::UNKNOWN)
-+      if (Arch != OffloadArch::Unknown)
-         return Arch;
-     }
-   }
--  return OffloadArch::UNKNOWN;
-+  return OffloadArch::Unknown;
- }
-
- /// Check to see if target architecture supports unified addressing which is
-@@ -2382,8 +2382,8 @@ void CGOpenMPRuntimeGPU::processRequiresDirective(const OMPRequiresDecl *D) {
-       case OffloadArch::Generic:
-       case OffloadArch::GRANITERAPIDS:
-       case OffloadArch::BMG_G21:
--      case OffloadArch::UNUSED:
--      case OffloadArch::UNKNOWN:
-+      case OffloadArch::Unused:
-+      case OffloadArch::Unknown:
-         break;
-       case OffloadArch::LAST:
-         llvm_unreachable("Unexpected GPU arch.");
-diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Driver.cpp
-index eb3f9cb..c8894a1 100644
---- a/clang/lib/Driver/Driver.cpp
-+++ b/clang/lib/Driver/Driver.cpp
-@@ -946,7 +946,7 @@ inferOffloadToolchains(Compilation &C, Action::OffloadKind Kind) {
-   llvm::DenseSet<llvm::StringRef> Triples;
-   for (llvm::StringRef Arch : Archs) {
-     OffloadArch ID = StringToOffloadArch(Arch);
--    if (ID == OffloadArch::UNKNOWN)
-+    if (ID == OffloadArch::Unknown)
-       ID = StringToOffloadArch(
-           getProcessorFromTargetID(llvm::Triple("amdgcn-amd-amdhsa"), Arch));
-
-@@ -961,12 +961,12 @@ inferOffloadToolchains(Compilation &C, Action::OffloadKind Kind) {
-       return llvm::DenseSet<llvm::StringRef>();
-     }
-     if (Kind == Action::OFK_OpenMP &&
--        (ID == OffloadArch::UNKNOWN || ID == OffloadArch::UNUSED)) {
-+        (ID == OffloadArch::Unknown || ID == OffloadArch::Unused)) {
-       C.getDriver().Diag(clang::diag::err_drv_failed_to_deduce_target_from_arch)
-           << Arch;
-       return llvm::DenseSet<llvm::StringRef>();
-     }
--    if (ID == OffloadArch::UNKNOWN || ID == OffloadArch::UNUSED) {
-+    if (ID == OffloadArch::Unknown || ID == OffloadArch::Unused) {
-       C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
-           << "offload" << Arch;
-       return llvm::DenseSet<llvm::StringRef>();
-@@ -3305,7 +3305,7 @@ class OffloadingActionBuilder final {
-     bool Relocatable = false;
-
-     /// Default GPU architecture if there's no one specified.
--    OffloadArch DefaultOffloadArch = OffloadArch::UNKNOWN;
-+    OffloadArch DefaultOffloadArch = OffloadArch::Unknown;
-
-     /// Compilation unit ID specified by option '-fuse-cuid=' or'-cuid='.
-     const CUIDOptions &CUIDOpts;
-@@ -3407,7 +3407,7 @@ class OffloadingActionBuilder final {
-
-       // If we have a fat binary, add it to the list.
-       if (CudaFatBinary) {
--        AddTopLevel(CudaFatBinary, OffloadArch::UNUSED);
-+        AddTopLevel(CudaFatBinary, OffloadArch::Unused);
-         CudaDeviceActions.clear();
-         CudaFatBinary = nullptr;
-         return;
-@@ -4669,12 +4669,12 @@ static StringRef getCanonicalArchString(Compilation &C,
-   OffloadArch Arch =
-       StringToOffloadArch(getProcessorFromTargetID(Triple, ArchStr));
-   if (Triple.isNVPTX() &&
--      (Arch == OffloadArch::UNKNOWN || !IsNVIDIAOffloadArch(Arch))) {
-+      (Arch == OffloadArch::Unknown || !IsNVIDIAOffloadArch(Arch))) {
-     C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
-         << "CUDA" << ArchStr;
-     return StringRef();
-   } else if (Triple.isAMDGPU() &&
--             (Arch == OffloadArch::UNKNOWN || !IsAMDOffloadArch(Arch))) {
-+             (Arch == OffloadArch::Unknown || !IsAMDOffloadArch(Arch))) {
-     C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
-         << "HIP" << ArchStr;
-     return StringRef();
-diff --git a/clang/lib/Driver/OffloadBundler.cpp b/clang/lib/Driver/OffloadBundler.cpp
-index f69ac41..6d446f2 100644
---- a/clang/lib/Driver/OffloadBundler.cpp
-+++ b/clang/lib/Driver/OffloadBundler.cpp
-@@ -95,7 +95,7 @@ OffloadTargetInfo::OffloadTargetInfo(const StringRef Target,
-       Components.size() == 6 ? Components.back() : "";
-   StringRef TargetId = TargetIdWithFeature.split(':').first;
-   if (!TargetId.empty() &&
--      clang::StringToOffloadArch(TargetId) != clang::OffloadArch::UNKNOWN)
-+      clang::StringToOffloadArch(TargetId) != clang::OffloadArch::Unknown)
-     this->TargetID = TargetIdWithFeature;
-   else
-     this->TargetID = "";
-diff --git a/clang/lib/Driver/ToolChains/Cuda.cpp b/clang/lib/Driver/ToolChains/Cuda.cpp
-index 6cc73ff..d97b926 100644
---- a/clang/lib/Driver/ToolChains/Cuda.cpp
-+++ b/clang/lib/Driver/ToolChains/Cuda.cpp
-@@ -319,7 +319,7 @@ void CudaInstallationDetector::AddCudaIncludeArgs(
-
- void CudaInstallationDetector::CheckCudaVersionSupportsArch(
-     OffloadArch Arch) const {
--  if (Arch == OffloadArch::UNKNOWN || Version == CudaVersion::UNKNOWN ||
-+  if (Arch == OffloadArch::Unknown || Version == CudaVersion::UNKNOWN ||
-       ArchsWithBadVersion[(int)Arch])
-     return;
-
-@@ -408,7 +408,7 @@ void NVPTX::Assembler::ConstructJob(Compilation &C, const JobAction &JA,
-
-   // Obtain architecture from the action.
-   OffloadArch gpu_arch = StringToOffloadArch(GPUArchName);
--  assert(gpu_arch != OffloadArch::UNKNOWN &&
-+  assert(gpu_arch != OffloadArch::Unknown &&
-          "Device action expected to have an architecture.");
-
-   // Check that our installation's ptxas supports gpu_arch.
-diff --git a/clang/lib/Sema/SemaDeclAttr.cpp b/clang/lib/Sema/SemaDeclAttr.cpp
-index 3f0ea5c..e6d3516 100644
---- a/clang/lib/Sema/SemaDeclAttr.cpp
-+++ b/clang/lib/Sema/SemaDeclAttr.cpp
-@@ -5732,7 +5732,7 @@ Sema::CreateLaunchBoundsAttr(const AttributeCommonInfo &CI, Expr *MaxThreads,
-   if (MaxBlocks) {
-     // '.maxclusterrank' ptx directive requires .target sm_90 or higher.
-     auto SM = getOffloadArch(Context.getTargetInfo());
--    if (SM == OffloadArch::UNKNOWN || SM < OffloadArch::SM_90) {
-+    if (SM == OffloadArch::Unknown || SM < OffloadArch::SM_90) {
-       Diag(MaxBlocks->getBeginLoc(), diag::warn_cuda_maxclusterrank_sm_90)
-           << OffloadArchToString(SM) << CI << MaxBlocks->getSourceRange();
-       // Ignore it by setting MaxBlocks to null;
diff --git a/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch b/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
deleted file mode 100644
index f458fd0cf8..0000000000
--- a/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 5dbd0a05f64a43849a7edde95a0e5f2323cd1f9d Mon Sep 17 00:00:00 2001
-From: Khem Raj <khem.raj@oss.qualcomm.com>
-Date: Tue, 31 Mar 2026 19:33:29 -0700
-Subject: [PATCH] libcxxabi: declare __gnu_unwind_frame in cxa_personality
-
-ARM EHABI builds of libcxxabi fail with clang-22+ because
-cxa_personality.cpp calls __gnu_unwind_frame without a visible
-declaration, triggering:
-
-  error: use of undeclared identifier '__gnu_unwind_frame'
-
-Add an extern "C" forward declaration before the EHABI unwind helper
-so the source compiles correctly.
-
-Upstream-Status: Submitted [https://github.com/llvm/llvm-project/pull/189787]
-Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
----
- libcxxabi/src/cxa_personality.cpp | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/libcxxabi/src/cxa_personality.cpp b/libcxxabi/src/cxa_personality.cpp
-index 35f4e3807724..ddff277cc7b8 100644
---- a/libcxxabi/src/cxa_personality.cpp
-+++ b/libcxxabi/src/cxa_personality.cpp
-@@ -1116,6 +1116,8 @@ __gxx_personality_seh0(PEXCEPTION_RECORD ms_exc, void *this_frame,
-
- #else
-
-+extern "C" _Unwind_Reason_Code __gnu_unwind_frame(_Unwind_Exception*,
-+                                                  _Unwind_Context*);
- // Helper function to unwind one frame.
- // ARM EHABI 7.3 and 7.4: If the personality function returns _URC_CONTINUE_UNWIND, the
- // personality routine should update the virtual register set (VRS) according to the
diff --git a/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch b/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
deleted file mode 100644
index 39e27ac12f..0000000000
--- a/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
+++ /dev/null
@@ -1,71 +0,0 @@
-From 965f9d87adb0a7376454374fbc140ab69bd796a9 Mon Sep 17 00:00:00 2001
-From: Florian Hahn <flo@fhahn.com>
-Date: Fri, 27 Mar 2026 13:02:51 +0000
-Subject: [PATCH] [LoopUnroll] Use MapVector for deterministic iteration order.
- (#188821)
-
-NonLoopBlocksIDom determines the order we adjust the DT, impacting DRT
-child ordering.
-
-Similarly, ExitInfos order impacts the order of SetDest, which applies
-DT updates.
-
-The order impacts collectChildrenInLoop, which in turn impacts the we
-process BBs in LICM. And this in turn impacts the order in which we
-perform alias queries.
-
-If the order is not deterministic, we sometimes get different NumNoAlias
-statistic counts, and possibly also different IR, although I have not
-confirmed the latter.
-
-Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/965f9d87adb0a7376454374fbc140ab69bd796a9]
-Signed-off-by: Sunilkumar Dora <sunilkumar.dora@windriver.com>
-Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
-
----
- llvm/lib/Transforms/Utils/LoopPeel.cpp   | 3 ++-
- llvm/lib/Transforms/Utils/LoopUnroll.cpp | 3 ++-
- 2 files changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/llvm/lib/Transforms/Utils/LoopPeel.cpp b/llvm/lib/Transforms/Utils/LoopPeel.cpp
-index 91737b5c30533..4c67d5a9ae680 100644
---- a/llvm/lib/Transforms/Utils/LoopPeel.cpp
-+++ b/llvm/lib/Transforms/Utils/LoopPeel.cpp
-@@ -11,6 +11,7 @@
-
- #include "llvm/Transforms/Utils/LoopPeel.h"
- #include "llvm/ADT/DenseMap.h"
-+#include "llvm/ADT/MapVector.h"
- #include "llvm/ADT/SmallVector.h"
- #include "llvm/ADT/Statistic.h"
- #include "llvm/Analysis/Loads.h"
-@@ -1121,7 +1122,7 @@ void llvm::peelLoop(Loop *L, unsigned PeelCount, bool PeelLast, LoopInfo *LI,
-   // later. Immediate dominator of such block might change, because we add more
-   // routes which can lead to the exit: we can reach it from the peeled
-   // iterations too.
--  DenseMap<BasicBlock *, BasicBlock *> NonLoopBlocksIDom;
-+  MapVector<BasicBlock *, BasicBlock *> NonLoopBlocksIDom;
-   for (auto *BB : L->blocks()) {
-     auto *BBDomNode = DT.getNode(BB);
-     SmallVector<BasicBlock *, 16> ChildrenToUpdate;
-diff --git a/llvm/lib/Transforms/Utils/LoopUnroll.cpp b/llvm/lib/Transforms/Utils/LoopUnroll.cpp
-index 6a2ccbea996bf..ab35d217f0d93 100644
---- a/llvm/lib/Transforms/Utils/LoopUnroll.cpp
-+++ b/llvm/lib/Transforms/Utils/LoopUnroll.cpp
-@@ -17,6 +17,7 @@
-
- #include "llvm/ADT/ArrayRef.h"
- #include "llvm/ADT/DenseMap.h"
-+#include "llvm/ADT/MapVector.h"
- #include "llvm/ADT/STLExtras.h"
- #include "llvm/ADT/ScopedHashTable.h"
- #include "llvm/ADT/SetVector.h"
-@@ -515,7 +516,7 @@ llvm::UnrollLoop(Loop *L, UnrollLoopOptions ULO, LoopInfo *LI,
-     BasicBlock *FirstExitingBlock = nullptr;
-     SmallVector<BasicBlock *> ExitingBlocks;
-   };
--  DenseMap<BasicBlock *, ExitInfo> ExitInfos;
-+  MapVector<BasicBlock *, ExitInfo> ExitInfos;
-   SmallVector<BasicBlock *, 4> ExitingBlocks;
-   L->getExitingBlocks(ExitingBlocks);
-   for (auto *ExitingBlock : ExitingBlocks) {
diff --git a/meta/recipes-devtools/clang/common-clang.inc b/meta/recipes-devtools/clang/common-clang.inc
index 9018094419..5d571e5fce 100644
--- a/meta/recipes-devtools/clang/common-clang.inc
+++ b/meta/recipes-devtools/clang/common-clang.inc
@@ -3,9 +3,9 @@ LLVM_DIR = "llvm${LLVM_RELEASE}"
 
 LLVM_HTTP ?= "https://github.com/llvm"
 
-MAJOR_VER = "22"
+MAJOR_VER = "23"
 MINOR_VER = "1"
-PATCH_VER = "8"
+PATCH_VER = "0"
 # could be 'rcX' or 'git' or empty ( for release )
 VER_SUFFIX = ""
 
diff --git a/meta/recipes-devtools/clang/common.inc b/meta/recipes-devtools/clang/common.inc
index e1e03872cd..0ca6951ff4 100644
--- a/meta/recipes-devtools/clang/common.inc
+++ b/meta/recipes-devtools/clang/common.inc
@@ -17,51 +17,45 @@ BASEURI ?= "${LLVM_HTTP}/llvm-project/releases/download/llvmorg-${PV}${VER_SUFFI
 UPSTREAM_CHECK_URI = "${LLVM_HTTP}/llvm-project/releases/"
 UPSTREAM_CHECK_REGEX = "releases/tag/llvmorg-?(?P<pver>\d+(\.\d+)+)"
 SOURCEDIR ?= "llvm-project-${PV}${VER_SUFFIX}.src"
-SRC_URI[sha256sum] = "922f1817a0df7b1489272d18134ee0087a8b068828f87ac63b9861b1a9965888"
+SRC_URI[sha256sum] = "ab1f0e3ec52448c33e8782eaf0422504b87c7b016b22514653ee0d8fcee479ff"
 
 SRC_URI = "\
     ${BASEURI} \
-    file://0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch \
-    file://0002-compiler-rt-support-a-new-embedded-linux-target.patch \
-    file://0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch \
-    file://0004-llvm-allow-env-override-of-exe-and-libdir-path.patch \
-    file://0005-clang-driver-Check-sysroot-for-ldso-path.patch \
-    file://0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch \
-    file://0007-clang-Prepend-trailing-to-sysroot.patch \
-    file://0009-clang-Define-releative-gcc-installation-dir.patch \
-    file://0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch \
-    file://0011-Check-for-atomic-double-intrinsics.patch \
-    file://0012-cmake-Fix-configure-for-packages-using-find_package.patch \
-    file://0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch \
-    file://0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch \
-    file://0015-clang-Use-python3-in-python-scripts.patch \
-    file://0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch \
-    file://0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch \
-    file://0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch \
-    file://0019-libunwind-Added-unw_backtrace-method.patch \
-    file://0020-lldb-Link-with-libatomic-on-x86.patch \
-    file://0021-compiler-rt-Enable-__int128-for-ppc32.patch \
-    file://0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch \
-    file://0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch \
-    file://0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch \
-    file://0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch \
-    file://0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch \
-    file://0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch \
-    file://0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch \
-    file://0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch \
-    file://0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch \
-    file://0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch \
-    file://0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch \
-    file://0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch \
-    file://0035-Prevent-revisiting-block-when-searching-for-noreturn.patch \
-    file://0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch \
-    file://0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch \
-    file://0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch \
-    file://0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch \
-    file://0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch \
-    file://0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch \
-    file://0042-guard-clang-tools-extra-test.patch \
-    file://0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch \
+    file://0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch \
+    file://0002-llvm-allow-env-override-of-exe-and-libdir-path.patch \
+    file://0003-clang-driver-Check-sysroot-for-ldso-path.patch \
+    file://0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch \
+    file://0005-clang-Prepend-trailing-to-sysroot.patch \
+    file://0006-clang-Define-releative-gcc-installation-dir.patch \
+    file://0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch \
+    file://0008-Check-for-atomic-double-intrinsics.patch \
+    file://0009-cmake-Fix-configure-for-packages-using-find_package.patch \
+    file://0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch \
+    file://0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch \
+    file://0012-clang-Use-python3-in-python-scripts.patch \
+    file://0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch \
+    file://0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch \
+    file://0015-libunwind-Added-unw_backtrace-method.patch \
+    file://0016-lldb-Link-with-libatomic-on-x86.patch \
+    file://0017-compiler-rt-Enable-__int128-for-ppc32.patch \
+    file://0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch \
+    file://0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch \
+    file://0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch \
+    file://0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch \
+    file://0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch \
+    file://0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch \
+    file://0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch \
+    file://0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch \
+    file://0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch \
+    file://0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch \
+    file://0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch \
+    file://0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch \
+    file://0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch \
+    file://0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch \
+    file://0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch \
+    file://0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch \
+    file://0034-guard-clang-tools-extra-test.patch \
+    file://0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch \
 "
 # Fallback to no-PIE if not set
 GCCPIE ??= ""
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 19:43   ` Khem Raj
  2026-08-30 12:58 ` [PATCH 03/11] openmp: Build via the LLVM runtimes entry point sunilkumar.dora
                   ` (9 subsequent siblings)
  11 siblings, 1 reply; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

Each release branch of the translator only builds against the
matching LLVM major. Move to the llvm_release_230 branch, pinned
at the v23.1.0 tag.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 ...translator_22.1.5.bb => spirv-llvm-translator_23.1.0.bb} | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
 rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb => spirv-llvm-translator_23.1.0.bb} (87%)

diff --git a/meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb b/meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb
similarity index 87%
rename from meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb
rename to meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb
index 1f80c6a27f..fd1dd9cfae 100644
--- a/meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb
+++ b/meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb
@@ -5,8 +5,8 @@ LICENSE = "NCSA"
 LIC_FILES_CHKSUM = "file://LICENSE.TXT;md5=47e311aa9caedd1b3abf098bd7814d1d"
 
 # pattern: llvm_branch_200, currently there are no minor releases, so, no llvm_branch_201
-SPIRV_BRANCH = "llvm_release_220"
-SRCREV = "27afcfe385cf542197dfde8c658e1f5ff53fc2fc"
+SPIRV_BRANCH = "llvm_release_230"
+SRCREV = "19a29d4376ab470909ba43ca014ae668fb1156c9"
 SRC_URI = " \
     git://github.com/KhronosGroup/SPIRV-LLVM-Translator;protocol=https;branch=${SPIRV_BRANCH};tag=v${PV} \
 "
@@ -18,7 +18,7 @@ DEPENDS = "llvm spirv-tools spirv-headers"
 inherit cmake pkgconfig lib_package
 
 EXTRA_OECMAKE = "\
-    -DBASE_LLVM_VERSION=22.1.0 \
+    -DBASE_LLVM_VERSION=23.1.0 \
     -DCMAKE_SKIP_BUILD_RPATH=ON \
     -DBUILD_SHARED_LIBS=ON \
     -DLLVM_EXTERNAL_SPIRV_HEADERS_SOURCE_DIR=${STAGING_INCDIR}/.. \
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 03/11] openmp: Build via the LLVM runtimes entry point
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0 sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 19:45   ` Khem Raj
  2026-08-30 12:58 ` [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23 sunilkumar.dora
                   ` (8 subsequent siblings)
  11 siblings, 1 reply; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

LLVM 23 removed the standalone build mode for openmp, so do_configure
fails with

  The legacy standalone build mode has been removed

Configure it through the runtimes build with LLVM_ENABLE_RUNTIMES=openmp,
the same way libcxx is built.

The runtimes build reads LLVM_LIBDIR_SUFFIX; nothing in LLVM 23 reads
OPENMP_LIBDIR_SUFFIX any more, so pass the standard variable like the
other clang-family recipes do. Without it openmp installs into lib/
while a multilib configuration packages lib64/, and do_package fails
with "installed but not shipped" for libomp.so, libarcher.so,
libompd.so and the cmake files.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 meta/recipes-devtools/clang/openmp_git.bb | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-devtools/clang/openmp_git.bb b/meta/recipes-devtools/clang/openmp_git.bb
index 2ba83d48c6..90d4911623 100644
--- a/meta/recipes-devtools/clang/openmp_git.bb
+++ b/meta/recipes-devtools/clang/openmp_git.bb
@@ -18,10 +18,11 @@ inherit cmake pkgconfig python3targetconfig
 DEPENDS += "elfutils libffi clang"
 
 EXTRA_OECMAKE += "-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-                  -DOPENMP_LIBDIR_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \
+                  -DLLVM_ENABLE_RUNTIMES=openmp \
+                  -DLLVM_LIBDIR_SUFFIX=${LLVM_LIBDIR_SUFFIX} \
                   "
 
-OECMAKE_SOURCEPATH = "${S}/openmp"
+OECMAKE_SOURCEPATH = "${S}/runtimes"
 
 PACKAGECONFIG ?= "ompt-tools offloading-plugin"
 
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (2 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 03/11] openmp: Build via the LLVM runtimes entry point sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 19:47   ` Khem Raj
  2026-08-30 12:58 ` [PATCH 05/11] rust: Do not pass the removed x86 amx-tf32 feature to " sunilkumar.dora
                   ` (7 subsequent siblings)
  11 siblings, 1 reply; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>

Backport upstream Rust commits to address build and oe-selftest
failures introduced by the LLVM 23 upgrade.

New patch:
0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
The backported changes update LLVM 23 compatibility in the Rust LLVM
wrapper and adjust affected LLVM codegen tests.

Selftest Changes:
Exclude the following Windows-specific test from oe-selftest,
as it is not relevant.
tests/assembly-llvm/x86_64-windows-float-abi.rs

Excluded tests:
+---------+---------+---------+
| Before  |  After  | Skipped |
+---------+---------+---------+
|   43    |   44    |   +1    |
+---------+---------+---------+

Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 meta/lib/oeqa/selftest/cases/rust.py          |   1 +
 ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
 meta/recipes-devtools/rust/rust-source.inc    |   1 +
 3 files changed, 663 insertions(+)
 create mode 100644 meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch

diff --git a/meta/lib/oeqa/selftest/cases/rust.py b/meta/lib/oeqa/selftest/cases/rust.py
index fa8a8c1e7c..645b5d5fbf 100644
--- a/meta/lib/oeqa/selftest/cases/rust.py
+++ b/meta/lib/oeqa/selftest/cases/rust.py
@@ -83,6 +83,7 @@ class RustSelfTestSystemEmulated(OESelftestTestCase, OEPTestResultTestCase):
                             'src/tools/tidy',
                             'tests/assembly-llvm/asm/aarch64-outline-atomics.rs',
                             'tests/assembly-llvm/c-variadic/arm.rs',
+                            'tests/assembly-llvm/x86_64-windows-float-abi.rs',
                             'tests/codegen-llvm/thread-local.rs',
                             'tests/mir-opt/',
                             'tests/run-make',
diff --git a/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
new file mode 100644
index 0000000000..1e1bf089f1
--- /dev/null
+++ b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
@@ -0,0 +1,661 @@
+Backport commits that fix build and oe-selftest failures seen with llvm 23
+
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/b8d3a4ac9cfeb81d1e929fe6eab0af4b77ba3bb4]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/d4a24cd6e18b98326429d8c7e7bbb269da14a5aa]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/20ac2125a2142c9bde53ca06d9b3cfb6941fd437]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/2d18054569d1169bfae7ce21e5c7111f32f16774]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/e2159107f6ebc615ba6a92960d65528baf90cd35]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/283a60b64339d611b76a4ed2f9286f417b269b2f]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/61d9ba28a99f073fbeb19dbb552ddf343aef62f0]
+
+Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
+
+diff --git a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
+index fe5b8edce4a..e4807f10805 100644
+--- a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
++++ b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
+@@ -49,6 +49,9 @@
+ #include "llvm/Transforms/Instrumentation/RealtimeSanitizer.h"
+ #include "llvm/Transforms/Instrumentation/ThreadSanitizer.h"
+ #include "llvm/Transforms/Scalar/AnnotationRemarks.h"
++#if LLVM_VERSION_GE(23, 0)
++#include "llvm/Transforms/Utils/AssignGUID.h"
++#endif
+ #include "llvm/Transforms/Utils/CanonicalizeAliases.h"
+ #include "llvm/Transforms/Utils/FunctionImportUtils.h"
+ #include "llvm/Transforms/Utils/NameAnonGlobals.h"
+@@ -925,6 +928,9 @@
+   if (NeedThinLTOBufferPasses) {
+     MPM.addPass(CanonicalizeAliasesPass());
+     MPM.addPass(NameAnonGlobalPass());
++#if LLVM_VERSION_GE(23, 0)
++    MPM.addPass(AssignGUIDPass());
++#endif
+   }
+   // For `-Copt-level=0`, and the pre-link fat/thin LTO stages.
+   if (ThinLTOBufferRef && *ThinLTOBufferRef == nullptr) {
+@@ -1464,6 +1470,9 @@
+         PB.registerLoopAnalyses(LAM);
+         PB.crossRegisterProxies(LAM, FAM, CGAM, MAM);
+         ModulePassManager MPM;
++#if LLVM_VERSION_GE(23, 0)
++        MPM.addPass(AssignGUIDPass());
++#endif
+         MPM.addPass(ThinLTOBitcodeWriterPass(OS, nullptr));
+         MPM.run(*unwrap(M), MAM);
+       } else {
+diff --git a/tests/codegen-llvm/bpf-allows-unaligned.rs b/tests/codegen-llvm/bpf-allows-unaligned.rs
+index c7a70d5b2e5..7e95a56d984 100644
+--- a/tests/codegen-llvm/bpf-allows-unaligned.rs
++++ b/tests/codegen-llvm/bpf-allows-unaligned.rs
+@@ -5,7 +5,7 @@
+ 
+ #[no_mangle]
+ #[target_feature(enable = "allows-misaligned-mem-access")]
+-// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg) unnamed_addr #0 {
++// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg) unnamed_addr #0
+ pub unsafe fn foo(arg: u8) -> u8 {
+     arg
+ }
+diff --git a/tests/codegen-llvm/branch-protection.rs b/tests/codegen-llvm/branch-protection.rs
+index ed1cb2cd137..11847c256d6 100644
+--- a/tests/codegen-llvm/branch-protection.rs
++++ b/tests/codegen-llvm/branch-protection.rs
+@@ -22,7 +22,7 @@
+ use minicore::*;
+ 
+ // A basic test function.
+-// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]] {
++// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]]
+ #[no_mangle]
+ pub fn test() {}
+ 
+diff --git a/tests/codegen-llvm/frame-pointer-cli-control.rs b/tests/codegen-llvm/frame-pointer-cli-control.rs
+index 911a5f03cbc..79cdfc70f1a 100644
+--- a/tests/codegen-llvm/frame-pointer-cli-control.rs
++++ b/tests/codegen-llvm/frame-pointer-cli-control.rs
+@@ -45,7 +45,7 @@
+ 
+ extern crate minicore;
+ 
+-// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
++// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
+ #[no_mangle]
+ pub fn peach(x: u32) -> u32 {
+     x
+diff --git a/tests/codegen-llvm/frame-pointer.rs b/tests/codegen-llvm/frame-pointer.rs
+index 1d0dd762826..a52d95a2386 100644
+--- a/tests/codegen-llvm/frame-pointer.rs
++++ b/tests/codegen-llvm/frame-pointer.rs
+@@ -18,7 +18,7 @@
+ extern crate minicore;
+ use minicore::*;
+ 
+-// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
++// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
+ #[no_mangle]
+ pub fn peach(x: u32) -> u32 {
+     x
+diff --git a/tests/codegen-llvm/gpu-convergent.rs b/tests/codegen-llvm/gpu-convergent.rs
+index bb9271ab699..376d65a3d4a 100644
+--- a/tests/codegen-llvm/gpu-convergent.rs
++++ b/tests/codegen-llvm/gpu-convergent.rs
+@@ -17,7 +17,7 @@
+     fn ext();
+ }
+ 
+-// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr #[[ATTR:[0-9]+]] {
++// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr #[[ATTR:[0-9]+]]
+ // CHECK: declare void @ext() unnamed_addr #[[ATTR]]
+ // CHECK: attributes #[[ATTR]] = {{.*}} convergent
+ #[no_mangle]
+diff --git a/tests/codegen-llvm/instrument-coverage/testprog.rs b/tests/codegen-llvm/instrument-coverage/testprog.rs
+index ef61ede6de8..67c49c438f9 100644
+--- a/tests/codegen-llvm/instrument-coverage/testprog.rs
++++ b/tests/codegen-llvm/instrument-coverage/testprog.rs
+@@ -101,7 +101,7 @@ fn main() {
+ // CHECK-SAME:   @__llvm_prf_nm
+ // CHECK-SAME:   section "llvm.metadata"
+ 
+-// CHECK:        define internal { {{.*}} } @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}} {
++// CHECK:        define internal { {{.*}} } @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}}
+ // CHECK-NEXT:   start:
+ // CHECK-NOT:    define internal
+ // CHECK:        atomicrmw add ptr
+@@ -109,7 +109,7 @@ fn main() {
+ 
+ // CHECK:        declare void @llvm.instrprof.increment(ptr, i64, i32, i32) #[[LLVM_INSTRPROF_INCREMENT_ATTR:[0-9]+]]
+ 
+-// WIN:          define linkonce_odr hidden i32 @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]] comdat {{.*}}{
++// WIN:          define linkonce_odr hidden i32 @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]] comdat {{.*}}
+ // WIN-NEXT:     %1 = load i32, ptr @__llvm_profile_runtime
+ // WIN-NEXT:     ret i32 %1
+ // WIN-NEXT:     }
+diff --git a/tests/codegen-llvm/link_section.rs b/tests/codegen-llvm/link_section.rs
+index f196ea86c44..61bde683c0a 100644
+--- a/tests/codegen-llvm/link_section.rs
++++ b/tests/codegen-llvm/link_section.rs
+@@ -29,7 +29,7 @@ pub enum E {
+ #[link_section = "__TEST,three"]
+ pub static VAR3: E = E::B(1.);
+ 
+-// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section "__TEST,four" {
++// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section "__TEST,four"
+ #[no_mangle]
+ #[link_section = "__TEST,four"]
+ pub fn fn1() {}
+diff --git a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
+index 7639ce7b104..5b1aa97ab33 100644
+--- a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
++++ b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
+@@ -7,21 +7,21 @@
+ 
+ pub fn foo(f: fn(i32) -> i32, arg: i32) -> i32 {
+     // CHECK-LABEL: define{{.*}}foo
+-    // CHECK-SAME:  {{.*}}![[TYPE1:[0-9]+]]
++    // CHECK-SAME:  {{.*}}!type ![[TYPE1:[0-9]+]]
+     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata !"_ZTSFu3i32S_E.normalized.generalized")
+     f(arg)
+ }
+ 
+ pub fn bar(f: fn(i32, i32) -> i32, arg1: i32, arg2: i32) -> i32 {
+     // CHECK-LABEL: define{{.*}}bar
+-    // CHECK-SAME:  {{.*}}![[TYPE2:[0-9]+]]
++    // CHECK-SAME:  {{.*}}!type ![[TYPE2:[0-9]+]]
+     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata !"_ZTSFu3i32S_S_E.normalized.generalized")
+     f(arg1, arg2)
+ }
+ 
+ pub fn baz(f: fn(i32, i32, i32) -> i32, arg1: i32, arg2: i32, arg3: i32) -> i32 {
+     // CHECK-LABEL: define{{.*}}baz
+-    // CHECK-SAME:  {{.*}}![[TYPE3:[0-9]+]]
++    // CHECK-SAME:  {{.*}}!type ![[TYPE3:[0-9]+]]
+     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata !"_ZTSFu3i32S_S_S_E.normalized.generalized")
+     f(arg1, arg2, arg3)
+ }
+diff --git a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
+index 35317b0dd39..3df2d569f9a 100644
+--- a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
++++ b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
+@@ -72,7 +72,7 @@ pub unsafe fn some_non_zero_from_atomic_get() -> Option<NonZeroUsize> {
+ ///
+ /// The way we check that the LLVM IR is correct is by making sure that neither
+ /// `panic` nor `unreachable` is part of the LLVM IR:
+-// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2() {{.*}} {
++// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2() {{.*}}
+ // CHECK-NOT: panic
+ // CHECK-NOT: unreachable
+ #[no_mangle]
+diff --git a/tests/codegen-llvm/target-feature-negative-implication.rs b/tests/codegen-llvm/target-feature-negative-implication.rs
+index a9cdca42839..376599738e5 100644
+--- a/tests/codegen-llvm/target-feature-negative-implication.rs
++++ b/tests/codegen-llvm/target-feature-negative-implication.rs
+@@ -13,7 +13,7 @@
+ #[no_mangle]
+ pub unsafe fn banana() {
+     // CHECK-LABEL: @banana()
+-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
+ }
+ 
+ // CHECK: attributes [[BANANAATTRS]]
+diff --git a/tests/codegen-llvm/target-feature-overrides.rs b/tests/codegen-llvm/target-feature-overrides.rs
+index 2adc8ee6f53..3bf05c7977e 100644
+--- a/tests/codegen-llvm/target-feature-overrides.rs
++++ b/tests/codegen-llvm/target-feature-overrides.rs
+@@ -23,7 +23,7 @@
+ #[no_mangle]
+ pub unsafe fn apple() -> u32 {
+     // CHECK-LABEL: @apple()
+-    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]] {
++    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]]
+     // CHECK: {{.*}}call{{.*}}@peach
+     peach()
+ }
+@@ -32,7 +32,7 @@ pub unsafe fn apple() -> u32 {
+ #[no_mangle]
+ pub unsafe fn banana() -> u32 {
+     // CHECK-LABEL: @banana()
+-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
+     // COMPAT: {{.*}}call{{.*}}@peach
+     // INCOMPAT: {{.*}}call{{.*}}@apple
+     apple() // Compatible for inline in COMPAT revision and can't be inlined in INCOMPAT
+diff --git a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
+index ecace722e0d..279780e3a7a 100644
+--- a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `aapcs-unwind` extern functions. `aapcs-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "aapcs" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "aapcs-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
+index 46c08b5fc4f..1b3312839e3 100644
+--- a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
+@@ -7,11 +7,11 @@
+ 
+ #![crate_type = "lib"]
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "C" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "C-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
+index 8e643d6ce49..6f4eafb353c 100644
+--- a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
+@@ -7,11 +7,11 @@
+ 
+ #![crate_type = "lib"]
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "cdecl" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "cdecl-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
+index 7df46813ed1..51c6fd15b9c 100644
+--- a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `fastcall-unwind` extern functions. `fastcall-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "fastcall" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "fastcall-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
+index cc06ee12549..b5fcea52b4d 100644
+--- a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // extern functions. `stdcall-unwind` functions MUST NOT have this attribute. We disable
+ // optimizations above to prevent LLVM from inferring the attribute.
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "stdcall" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "stdcall-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
+index 5f910248346..15fce95fe28 100644
+--- a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
+@@ -7,11 +7,11 @@
+ 
+ #![crate_type = "lib"]
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "system" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "system-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
+index 69bfaf80b4b..1293e7c0a5f 100644
+--- a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `sysv64-unwind` extern functions. `sysv64-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "sysv64" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "sysv64-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
+index 05f6b8b70e1..a9b6c34ee58 100644
+--- a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `thiscall-unwind` extern functions. `thiscall-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "thiscall" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "thiscall-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
+index d001a16b32a..8cedb55ae1d 100644
+--- a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `vectorcall-unwind` extern functions. `vectorcall-unwind` functions MUST NOT have this attribute.
+ // We disable optimizations above to prevent LLVM from inferring the attribute.
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "vectorcall" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "vectorcall-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
+index 257f00b54e4..2a3ad330406 100644
+--- a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `win64-unwind` extern functions. `win64-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+ 
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "win64" fn rust_item_that_cannot_unwind() {}
+ 
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "win64-unwind" fn rust_item_that_can_unwind() {}
+ 
+diff --git a/tests/assembly-llvm/slice-is_ascii.rs b/tests/assembly-llvm/slice-is_ascii.rs
+index e53cd5160cf..6d660e78147 100644
+--- a/tests/assembly-llvm/slice-is_ascii.rs
++++ b/tests/assembly-llvm/slice-is_ascii.rs
+@@ -6,6 +6,11 @@
+ //@ only-x86_64
+ //@ ignore-sgx
+
++// No longer optimizes as desired, tracked at:
++// https://github.com/rust-lang/rust/issues/154141
++// https://github.com/llvm/llvm-project/issues/209216
++//@ max-llvm-major-version: 22
++
+ #![feature(str_internals)]
+
+ // CHECK-LABEL: is_ascii_simple_demo:
+diff --git a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
+index 40d16886c6d..d3698fda5fe 100644
+--- a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
++++ b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
+@@ -1,12 +1,16 @@
+ // verify that simd mask reductions do not introduce additional bit shift operations
+ //@ add-minicore
+-//@ revisions: x86 aarch64
++//@ revisions: x86 aarch64-llvm22 aarch64
+ //@ [x86] compile-flags: --target=x86_64-unknown-linux-gnu -C llvm-args=-x86-asm-syntax=intel
+ // Set the base cpu explicitly, in case the default has been changed.
+ //@ [x86] compile-flags: -C target-cpu=x86-64
+ //@ [x86] needs-llvm-components: x86
++//@ [aarch64-llvm22] compile-flags: --target=aarch64-unknown-linux-gnu
++//@ [aarch64-llvm22] needs-llvm-components: aarch64
++//@ [aarch64-llvm22] max-llvm-major-version: 22
+ //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
+ //@ [aarch64] needs-llvm-components: aarch64
++//@ [aarch64] min-llvm-version: 23
+ //@ assembly-output: emit-asm
+ //@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
+
+@@ -33,12 +37,19 @@
+     // x86-NEXT: {{cmp ax, -1|cmp eax, 65535|xor eax, 65535}}
+     // x86-NEXT: sete al
+     //
++    // aarch64-llvm22-NOT: shl
++    // aarch64-llvm22: cmge v0.16b, v0.16b, #0
++    // aarch64-llvm22-DAG: mov [[REG1:[a-z0-9]+]], #1
++    // aarch64-llvm22-DAG: umaxv b0, v0.16b
++    // aarch64-llvm22-NEXT: fmov [[REG2:[a-z0-9]+]], s0
++    // aarch64-llvm22-NEXT: bic w0, [[REG1]], [[REG2]]
++    //
+     // aarch64-NOT: shl
+     // aarch64: cmge v0.16b, v0.16b, #0
+-    // aarch64-DAG: mov [[REG1:[a-z0-9]+]], #1
+-    // aarch64-DAG: umaxv b0, v0.16b
+-    // aarch64-NEXT: fmov [[REG2:[a-z0-9]+]], s0
+-    // aarch64-NEXT: bic w0, [[REG1]], [[REG2]]
++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
++    // aarch64-NEXT: cmp [[REG2]], #0
++    // aarch64-NEXT: cset w0, eq
+     simd_reduce_all(m)
+ }
+
+@@ -50,10 +61,17 @@
+     // x86-NEXT: test eax, eax
+     // x86-NEXT: setne al
+     //
++    // aarch64-llvm22-NOT: shl
++    // aarch64-llvm22: cmlt v0.16b, v0.16b, #0
++    // aarch64-llvm22-NEXT: umaxv b0, v0.16b
++    // aarch64-llvm22-NEXT: fmov [[REG:[a-z0-9]+]], s0
++    // aarch64-llvm22-NEXT: and w0, [[REG]], #0x1
++    //
+     // aarch64-NOT: shl
+     // aarch64: cmlt v0.16b, v0.16b, #0
+-    // aarch64-NEXT: umaxv b0, v0.16b
+-    // aarch64-NEXT: fmov [[REG:[a-z0-9]+]], s0
+-    // aarch64-NEXT: and w0, [[REG]], #0x1
++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
++    // aarch64-NEXT: cmp [[REG2]], #0
++    // aarch64-NEXT: cset w0, ne
+     simd_reduce_any(m)
+ }
+diff --git a/tests/codegen-llvm/asm/global_asm.rs b/tests/codegen-llvm/asm/global_asm.rs
+index 32075daa3cf..8c1c4a3b588 100644
+--- a/tests/codegen-llvm/asm/global_asm.rs
++++ b/tests/codegen-llvm/asm/global_asm.rs
+@@ -7,10 +7,10 @@
+
+ use std::arch::global_asm;
+
+-// CHECK-LABEL: foo
+ // CHECK: module asm
++// CHECK-LABEL: foo
+ // this regex will capture the correct unconditional branch inst.
+-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
++// CHECK: "{{[[:space:]]+}}jmp baz"
+ global_asm!(
+     r#"
+     .global foo
+diff --git a/tests/codegen-llvm/asm/global_asm_include.rs b/tests/codegen-llvm/asm/global_asm_include.rs
+index 98be9c3e333..cad9901336b 100644
+--- a/tests/codegen-llvm/asm/global_asm_include.rs
++++ b/tests/codegen-llvm/asm/global_asm_include.rs
+@@ -7,9 +7,9 @@
+
+ use std::arch::global_asm;
+
+-// CHECK-LABEL: foo
+ // CHECK: module asm
+-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
++// CHECK-LABEL: foo
++// CHECK: "{{[[:space:]]+}}jmp baz"
+ global_asm!(include_str!("foo.s"));
+
+ extern "C" {
+diff --git a/tests/codegen-llvm/asm/global_asm_x2.rs b/tests/codegen-llvm/asm/global_asm_x2.rs
+index 9e3a00f0680..8c6f38289de 100644
+--- a/tests/codegen-llvm/asm/global_asm_x2.rs
++++ b/tests/codegen-llvm/asm/global_asm_x2.rs
+@@ -8,12 +8,12 @@
+
+ use core::arch::global_asm;
+
+-// CHECK-LABEL: foo
+ // CHECK: module asm
+-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
++// CHECK-LABEL: foo
++// CHECK: "{{[[:space:]]+}}jmp baz"
+ // any other global_asm will be appended to this first block, so:
+ // CHECK-LABEL: bar
+-// CHECK: module asm "{{[[:space:]]+}}jmp quux"
++// CHECK: "{{[[:space:]]+}}jmp quux"
+ global_asm!(
+     r#"
+     .global foo
+diff --git a/tests/codegen-llvm/array-cmp.rs b/tests/codegen-llvm/array-cmp.rs
+index 0106b9c15c1..5b0a802f409 100644
+--- a/tests/codegen-llvm/array-cmp.rs
++++ b/tests/codegen-llvm/array-cmp.rs
+@@ -2,6 +2,9 @@
+
+ //@ compile-flags: -C opt-level=2
+ //@ needs-deterministic-layouts (checks depend on tuple layout)
++//@ revisions: LLVM22 LLVM23
++//@ [LLVM22] max-llvm-major-version: 22
++//@ [LLVM23] min-llvm-version: 23
+
+ #![crate_type = "lib"]
+
+@@ -66,7 +69,8 @@ pub fn compare() -> bool {
+     // CHECK-NEXT: br i1 %[[EQ01]], label %{{.+}}, label %[[EXIT_U]]
+
+     // CHECK: [[DONE]]:
+-    // CHECK: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [ %{{.+}}, %[[EXIT_U]] ], [ true, %[[L11]] ]
++    // LLVM22: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [ %{{.+}}, %[[EXIT_U]] ], [ true, %[[L11]] ]
++    // LLVM23: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_U]] ], [ %{{.+}}, %[[EXIT_S]] ], [ true, %[[L11]] ]
+     // CHECK: ret i1 %[[RET]]
+
+     a <= b
+diff --git a/tests/codegen-llvm/enum/enum-match.rs b/tests/codegen-llvm/enum/enum-match.rs
+index 6d8b97328f8..a0cba452e12 100644
+--- a/tests/codegen-llvm/enum/enum-match.rs
++++ b/tests/codegen-llvm/enum/enum-match.rs
+@@ -1,5 +1,8 @@
+ //@ compile-flags: -Copt-level=1
+ //@ only-64bit
++//@ revisions: LLVM22 LLVM23
++//@ [LLVM22] max-llvm-major-version: 22
++//@ [LLVM23] min-llvm-version: 23
+
+ #![crate_type = "lib"]
+ #![feature(core_intrinsics)]
+@@ -18,8 +21,9 @@ pub enum Enum0 {
+ // CHECK-LABEL: define{{( dso_local)?}} noundef{{( range\(i8 [0-9]+, [0-9]+\))?}} i8 @match0(i8{{.+}}%0)
+ // CHECK-NEXT: start:
+ // CHECK-NEXT: %[[IS_B:.+]] = icmp eq i8 %0, 2
+-// CHECK-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
+-// CHECK-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
++// LLVM22-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
++// LLVM22-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
++// LLVM23-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %0
+ // CHECK-NEXT: ret i8 %[[R]]
+ #[no_mangle]
+ pub fn match0(e: Enum0) -> u8 {
+diff --git a/tests/assembly-llvm/simd-bitmask.rs b/tests/assembly-llvm/simd-bitmask.rs
+index 98f63c165f3..e8bb335c5b0 100644
+--- a/tests/assembly-llvm/simd-bitmask.rs
++++ b/tests/assembly-llvm/simd-bitmask.rs
+@@ -11,7 +11,7 @@
+ //@ [aarch64] min-llvm-version: 23
+ //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
+ //@ [aarch64] needs-llvm-components: aarch64
+-//@ [aarch64-llvm-pre-23] ignore-llvm-version: 23 - 99
++//@ [aarch64-llvm-pre-23] max-llvm-major-version: 22
+ //@ [aarch64-llvm-pre-23] compile-flags: --target=aarch64-unknown-linux-gnu
+ //@ [aarch64-llvm-pre-23] needs-llvm-components: aarch64
+ //@ assembly-output: emit-asm
+diff --git a/tests/codegen-llvm/array-equality.rs b/tests/codegen-llvm/array-equality.rs
+index 706caebdcb6..c0f716b6067 100644
+--- a/tests/codegen-llvm/array-equality.rs
++++ b/tests/codegen-llvm/array-equality.rs
+@@ -1,5 +1,5 @@
+ //@ revisions: llvm-current llvm-next
+-//@[llvm-current] ignore-llvm-version: 23-99
++//@[llvm-current] max-llvm-major-version: 22
+ //@[llvm-next] min-llvm-version: 23
+ //@ compile-flags: -Copt-level=3 -Z merge-functions=disabled
+ //@ only-x86_64
+diff --git a/tests/ui/explicit-tail-calls/support/bystack.rs b/tests/ui/explicit-tail-calls/support/bystack.rs
+index ddd9c79f5c7..c89ad194f8b 100644
+--- a/tests/ui/explicit-tail-calls/support/bystack.rs
++++ b/tests/ui/explicit-tail-calls/support/bystack.rs
+@@ -36,11 +36,11 @@
+ //@ revisions: loongarch32
+ //@[loongarch32] compile-flags: --target loongarch32-unknown-none
+ //@[loongarch32] needs-llvm-components: loongarch
+-//@[loongarch32] ignore-llvm-version: 22 - 23
++//@[loongarch32] max-llvm-major-version: 21
+ //@ revisions: loongarch64
+ //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
+ //@[loongarch64] needs-llvm-components: loongarch
+-//@[loongarch64] ignore-llvm-version: 22 - 23
++//@[loongarch64] max-llvm-major-version: 21
+ //@ revisions: bpf
+ //@[bpf] compile-flags: --target bpfeb-unknown-none
+ //@[bpf] needs-llvm-components: bpf
+diff --git a/tests/ui/explicit-tail-calls/support/byval.rs b/tests/ui/explicit-tail-calls/support/byval.rs
+index f451a953f2a..e6f26b9292e 100644
+--- a/tests/ui/explicit-tail-calls/support/byval.rs
++++ b/tests/ui/explicit-tail-calls/support/byval.rs
+@@ -36,11 +36,11 @@
+ //@ revisions: loongarch32
+ //@[loongarch32] compile-flags: --target loongarch32-unknown-none
+ //@[loongarch32] needs-llvm-components: loongarch
+-//@[loongarch32] ignore-llvm-version: 22 - 23
++//@[loongarch32] max-llvm-major-version: 21
+ //@ revisions: loongarch64
+ //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
+ //@[loongarch64] needs-llvm-components: loongarch
+-//@[loongarch64] ignore-llvm-version: 22 - 23
++//@[loongarch64] max-llvm-major-version: 21
+ //@ revisions: bpf
+ //@[bpf] compile-flags: --target bpfeb-unknown-none
+ //@[bpf] needs-llvm-components: bpf
+diff --git a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
+index 5834255f3d3..c3090a20e4d 100644
+--- a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
++++ b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
+@@ -14,7 +14,6 @@ pub unsafe fn foo(x: &mut Copied<Iter<'_, u32>>) -> u32 {
+     // CHECK-NOT: br {{.*}}
+     // CHECK-NOT: select
+     // CHECK: [[RET:%.*]] = load i32, ptr
+-    // CHECK-NEXT: assume
+-    // CHECK-NEXT: ret i32 [[RET]]
++    // CHECK: ret i32 [[RET]]
+     x.next().unwrap_unchecked()
+ }
diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc
index dd3e89a097..d87271b29c 100644
--- a/meta/recipes-devtools/rust/rust-source.inc
+++ b/meta/recipes-devtools/rust/rust-source.inc
@@ -7,6 +7,7 @@ SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n
             file://0001-src-core-build_steps-tool.rs-switch-off-lto-for-rust.patch;patchdir=${RUSTSRC} \
             file://0002-Fix-rust-build-failure-with-unstable-options.patch;patchdir=${RUSTSRC} \
             file://0003-bootstrap-skip-StdarchVerify-when-remote-testing.patch;patchdir=${RUSTSRC} \
+            file://0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch;patchdir=${RUSTSRC} \
 "
 SRC_URI[rust.sha256sum] = "271fa73d8174f53d713c46a8310da7bf7cfdcfb8b7cfd1c2b74b84a83ae9fb1e"
 
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 05/11] rust: Do not pass the removed x86 amx-tf32 feature to LLVM 23
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (3 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23 sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 06/11] clang: Disable clangd's decision-forest completion model on powerpc sunilkumar.dora
                   ` (6 subsequent siblings)
  11 siblings, 0 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

LLVM 23 removed the x86 amx-tf32 subtarget feature, so a rustc built
against LLVM 23 aborts at startup with

  "+amx-tf32" is not a recognized feature for this target

Gate the feature out of to_llvm_features for LLVM >= 23. rust dropped
the feature entirely after 1.98
(https://github.com/rust-lang/rust/pull/159310), but backporting that
would change stable rust behaviour, while a version guard keeps this
rust working against older LLVM majors too.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 ...llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch | 38 +++++++++++++++++++
 meta/recipes-devtools/rust/rust-source.inc    |  1 +
 2 files changed, 39 insertions(+)
 create mode 100644 meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch

diff --git a/meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch b/meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch
new file mode 100644
index 0000000000..99fcd334c7
--- /dev/null
+++ b/meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch
@@ -0,0 +1,38 @@
+From: Sunil Dora <sunilkumar.dora@windriver.com>
+Date: Wed, 26 Aug 2026 16:30:00 +0530
+Subject: [PATCH] rustc_codegen_llvm: do not pass amx-tf32 to LLVM 23
+
+LLVM 23 removed the x86 amx-tf32 subtarget feature
+(https://github.com/llvm/llvm-project/pull/207673). rust 1.98 still
+lists it in the x86 table in rustc_target, so a rustc built against
+LLVM 23 aborts at startup with
+
+  '+amx-tf32' is not a recognized feature for this target
+
+Skip the feature in to_llvm_features when the LLVM in use is 23 or
+newer, in the same style the surrounding code already uses for
+avx10.1/avx10.2 on older LLVM majors. amx-tf32 is the only x86
+feature LLVM 23 removed; the rest of the table still matches X86.td.
+
+rust dropped the feature outright after 1.98
+(https://github.com/rust-lang/rust/pull/159310), which requires
+LLVM 23 or newer unconditionally. This recipe builds against whatever
+LLVM major the layer provides, so the version guard is kept instead.
+
+Upstream-Status: Inappropriate [rust dropped the feature after 1.98 via https://github.com/rust-lang/rust/pull/159310; this guard only exists to build 1.98 against more than one LLVM major]
+Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
+---
+ compiler/rustc_codegen_llvm/src/llvm_util.rs | 2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/compiler/rustc_codegen_llvm/src/llvm_util.rs
++++ b/compiler/rustc_codegen_llvm/src/llvm_util.rs
+@@ -286,6 +286,8 @@
+                     s,
+                     smallvec![TargetFeatureFoldStrength::EnableOnly("evex512")],
+                 )),
++                // AMX-TF32 was removed from LLVM 23
++                "amx-tf32" if major >= 23 => None,
+                 "avx10.1" if major < 22 => Some(LLVMFeature::new("avx10.1-512")),
+                 "avx10.2" if major < 22 => Some(LLVMFeature::new("avx10.2-512")),
+                 "apxf" => Some(LLVMFeature::with_dependencies(
diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc
index d87271b29c..f40f1652b2 100644
--- a/meta/recipes-devtools/rust/rust-source.inc
+++ b/meta/recipes-devtools/rust/rust-source.inc
@@ -8,6 +8,7 @@ SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n
             file://0002-Fix-rust-build-failure-with-unstable-options.patch;patchdir=${RUSTSRC} \
             file://0003-bootstrap-skip-StdarchVerify-when-remote-testing.patch;patchdir=${RUSTSRC} \
             file://0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch;patchdir=${RUSTSRC} \
+            file://0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch;patchdir=${RUSTSRC} \
 "
 SRC_URI[rust.sha256sum] = "271fa73d8174f53d713c46a8310da7bf7cfdcfb8b7cfd1c2b74b84a83ae9fb1e"
 
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 06/11] clang: Disable clangd's decision-forest completion model on powerpc
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (4 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 05/11] rust: Do not pass the removed x86 amx-tf32 feature to " sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 07/11] pango: Don't turn clang 23's -Wunused-but-set-global into an error sunilkumar.dora
                   ` (5 subsequent siblings)
  11 siblings, 0 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

The generated CompletionModel.cpp overflows 16-bit branch displacements
on ppc32 and the assembler rejects it with thousands of

  {standard input}:177591: Error: operand out of range (0x81f8 is not
  between 0xffffffffffff8000 and 0x7fff)

Build clangd with -DCLANGD_DECISION_FOREST=OFF on powerpc, which falls
back to the heuristic completion ranking.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 meta/recipes-devtools/clang/clang_git.bb | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/meta/recipes-devtools/clang/clang_git.bb b/meta/recipes-devtools/clang/clang_git.bb
index a8c5e8cb2d..c54a49b618 100644
--- a/meta/recipes-devtools/clang/clang_git.bb
+++ b/meta/recipes-devtools/clang/clang_git.bb
@@ -75,6 +75,10 @@ EXTRA_OECMAKE += "-DLLVM_ENABLE_ASSERTIONS=OFF \
                   -DCMAKE_STRIP=${STAGING_BINDIR_NATIVE}/llvm-strip \
 "
 
+# The generated completion model overflows ppc32's 16-bit branch range
+# ("operand out of range" from gas); use the heuristic ranking instead.
+EXTRA_OECMAKE:append:powerpc = " -DCLANGD_DECISION_FOREST=OFF"
+
 CLANG_ENABLE_TESTSUITE ??= "0"
 CLANG_TESTSUITE_FLAGS = "\
                   -DCLANG_INCLUDE_TESTS=ON \
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 07/11] pango: Don't turn clang 23's -Wunused-but-set-global into an error
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (5 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 06/11] clang: Disable clangd's decision-forest completion model on powerpc sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 08/11] ovmf: Fix memcpy alias prototype for clang 23 sunilkumar.dora
                   ` (4 subsequent siblings)
  11 siblings, 0 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

clang 23 added -Wunused-but-set-global to the -Wunused-but-set-variable
group, which pango promotes to an error:

  pango/pango-fontset.c:36:1: error: variable 'pango_fontset_parent_class'
  set but not used [-Werror,-Wunused-but-set-global]

It fires on the parent_class variables emitted by GLib's G_DEFINE_TYPE
macros. Keep the warning visible but not fatal. gcc builds are
unaffected as meson only passes flags the compiler supports.

Reported upstream with patches attached: the meson change as pango
issue #900 and the underlying GLib macro fix as glib issue #4038.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 ...ror-on-clang-s-unused-but-set-global.patch | 28 +++++++++++++++++++
 meta/recipes-graphics/pango/pango_1.58.0.bb   |  1 +
 2 files changed, 29 insertions(+)
 create mode 100644 meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch

diff --git a/meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch b/meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
new file mode 100644
index 0000000000..2c3788abdf
--- /dev/null
+++ b/meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
@@ -0,0 +1,28 @@
+From: Sunil Dora <sunilkumar.dora@windriver.com>
+Date: Wed, 20 Aug 2026 10:45:00 +0530
+Subject: [PATCH] meson: don't error on clang's -Wunused-but-set-global
+
+clang 23 added -Wunused-but-set-global to the -Wunused-but-set-variable
+group, so the -Werror=unused-but-set-variable in test_cflags now turns
+it into an error. It fires on the <type>_parent_class variables that
+GLib's G_DEFINE_TYPE family of macros emit, which pango cannot fix, and
+on a few deliberately write-only globals in the test suite.
+
+Keep the warning visible but not fatal. gcc does not know this warning
+group, so cc.get_supported_arguments() drops the flag there.
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/pango/-/issues/900]
+Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
+---
+--- a/meson.build
++++ b/meson.build
+@@ -148,6 +148,9 @@
+     '-Werror=empty-body',
+     '-Werror=write-strings',
+     '-Werror=unused-but-set-variable',
++    # clang 23 made this part of the group above; it fires on GLib's
++    # G_DEFINE_TYPE boilerplate, which pango cannot fix.
++    '-Wno-error=unused-but-set-global',
+     '-Wundef', # FIXME: https://bugzilla.gnome.org/show_bug.cgi?id=792481
+   ]
+ 
diff --git a/meta/recipes-graphics/pango/pango_1.58.0.bb b/meta/recipes-graphics/pango/pango_1.58.0.bb
index 6e1aebad1d..0c9e26f39c 100644
--- a/meta/recipes-graphics/pango/pango_1.58.0.bb
+++ b/meta/recipes-graphics/pango/pango_1.58.0.bb
@@ -18,6 +18,7 @@ UPSTREAM_CHECK_REGEX = "pango-(?P<pver>\d+\.(?!9\d+)\d+\.\d+)"
 GIR_MESON_ENABLE_FLAG = "enabled"
 GIR_MESON_DISABLE_FLAG = "disabled"
 
+SRC_URI += "file://0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch"
 SRC_URI[archive.sha256sum] = "bc5bad6213ad4886a47d1e80292fd850b64159b50db67917a43d9ea80ee2298a"
 
 DEPENDS = "glib-2.0 glib-2.0-native fontconfig freetype virtual/libiconv cairo harfbuzz fribidi"
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 08/11] ovmf: Fix memcpy alias prototype for clang 23
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (6 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 07/11] pango: Don't turn clang 23's -Wunused-but-set-global into an error sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 09/11] vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error sunilkumar.dora
                   ` (3 subsequent siblings)
  11 siblings, 0 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

The memcpy alias in CryptoPkg's IntrinsicLib declares its size
parameter as unsigned int while the aliasee uses size_t. clang 23
diagnoses that through the new -Wattribute-alias, which the CLANGDWARF
build's -Werror turns into

  CopyMem.c:29:17: error: alias and aliasee have different types
  'void *(void *, const void *, unsigned int)' and
  'void *(void *, const void *, size_t)' [-Werror,-Wattribute-alias]

Declare the alias with size_t to match.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 ...sicLib-fix-memcpy-alias-prototype-fo.patch | 35 +++++++++++++++++++
 meta/recipes-core/ovmf/ovmf_git.bb            |  1 +
 2 files changed, 36 insertions(+)
 create mode 100644 meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch

diff --git a/meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch b/meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch
new file mode 100644
index 0000000000..0921f21347
--- /dev/null
+++ b/meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch
@@ -0,0 +1,35 @@
+From: Sunil Dora <sunilkumar.dora@windriver.com>
+Date: Wed, 20 Aug 2026 10:45:00 +0530
+Subject: [PATCH] CryptoPkg/IntrinsicLib: fix memcpy alias prototype for clang
+
+The clang-only memcpy alias declares its size parameter as unsigned int
+while the __memcpy aliasee uses size_t (UINTN, unsigned long long on
+X64). clang 23 diagnoses mismatched alias/aliasee types via the new
+-Wattribute-alias warning, which the CLANGDWARF build's -Werror turns
+into a hard error:
+
+  CopyMem.c:29:17: error: alias and aliasee have different types
+  'void *(void *, const void *, unsigned int)' and
+  'void *(void *, const void *, size_t)' [-Werror,-Wattribute-alias]
+
+Declare the alias with size_t, matching the aliasee on every
+architecture (UINTN is unsigned int on IA32, unsigned long long on X64).
+
+Upstream-Status: Submitted [https://github.com/tianocore/edk2/pull/13038]
+Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
+---
+--- a/CryptoPkg/Library/IntrinsicLib/CopyMem.c
++++ b/CryptoPkg/Library/IntrinsicLib/CopyMem.c
+@@ -29,9 +29,9 @@
+ __attribute__ ((__alias__ ("__memcpy")))
+ void *
+ memcpy (
+-  void          *dest,
+-  const void    *src,
+-  unsigned int  count
++  void        *dest,
++  const void  *src,
++  size_t      count
+   );
+ 
+ #else
diff --git a/meta/recipes-core/ovmf/ovmf_git.bb b/meta/recipes-core/ovmf/ovmf_git.bb
index 660aefcf46..bf69108f0a 100644
--- a/meta/recipes-core/ovmf/ovmf_git.bb
+++ b/meta/recipes-core/ovmf/ovmf_git.bb
@@ -19,6 +19,7 @@ SRC_URI = "gitsm://github.com/tianocore/edk2.git;branch=master;protocol=https;ta
            file://0002-BaseTools-makefile-adjust-to-build-in-under-bitbake.patch \
            file://0003-debug-prefix-map.patch \
            file://0004-reproducible.patch \
+           file://0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch \
            "
 
 PV = "edk2-stable202605"
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 09/11] vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (7 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 08/11] ovmf: Fix memcpy alias prototype for clang 23 sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 10/11] gettext: Export a fully-flagged Objective-C compiler sunilkumar.dora
                   ` (2 subsequent siblings)
  11 siblings, 0 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

clang 23's lifetime analysis flags the framework's
postprocessing_computepass.cpp taking .begin() of a temporary, and the
project builds with -Werror:

  framework/rendering/postprocessing_computepass.cpp:154:33: error:
  object backing the pointer will be destroyed at the end of the
  full-expression [-Werror,-Wdangling-gsl]

The warning is a true positive: get_resources() returns a vector by
value, so the code compares iterators from two different temporaries
and later dereferences a dangling one. The affected class is unused
(Vulkan-Samples issue #841) but still compiled everywhere. Reported
upstream with analysis and a proposed fix:
https://github.com/KhronosGroup/Vulkan-Samples/issues/1570

Fixing the framework source is upstream's call; from the recipe, extend
the existing clang workaround flags to keep the warning non-fatal.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 meta/recipes-graphics/vulkan/vulkan-samples_git.bb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/meta/recipes-graphics/vulkan/vulkan-samples_git.bb b/meta/recipes-graphics/vulkan/vulkan-samples_git.bb
index 75d7a39eb6..3d965ff22e 100644
--- a/meta/recipes-graphics/vulkan/vulkan-samples_git.bb
+++ b/meta/recipes-graphics/vulkan/vulkan-samples_git.bb
@@ -31,6 +31,8 @@ EXTRA_OECMAKE += "-DVKB_WSI_SELECTION=D2D"
 
 # Clang is fussy about incompatible options on aarch64/x86_64
 # x86_64-poky-linux-clang++: error: overriding '-ffp-model=precise' option with '-ffp-contract=fast' [-Werror,-Woverriding-option]
-CXXFLAGS:append:toolchain-clang = " -Wno-error=overriding-option"
+# clang 23's -Wdangling-gsl also flags framework code taking .begin() of a
+# temporary (postprocessing_computepass.cpp); keep it a warning, not an error.
+CXXFLAGS:append:toolchain-clang = " -Wno-error=overriding-option -Wno-error=dangling-gsl"
 
 COMPATIBLE_HOST = "(aarch64|x86_64).*-linux"
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 10/11] gettext: Export a fully-flagged Objective-C compiler
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (8 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 09/11] vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 12:58 ` [PATCH 11/11] clang/llvm: Ignore tests fail with clang/llvm 23 upgrade sunilkumar.dora
  2026-08-30 19:53 ` [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 Khem Raj
  11 siblings, 0 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Sunil Dora <sunilkumar.dora@windriver.com>

configure probes for an Objective-C compiler and picks the bare
${HOST_PREFIX}clang, which has no default sysroot, so libtool's probes
search the build host's library paths and do_configure fails QA with

  ERROR: gettext-1.0-r0 do_configure: QA Issue: This autoconf log
  indicates errors, it looked at host include and/or library paths
  while determining system capabilities. [configure-unsafe]

Export OBJC as the fully-flagged C compiler so the probes use the right
sysroot, and drop OBJC/OBJCFLAGS from the ptest environment file like
the existing CC/CXX handling, to avoid recording build paths.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 ...nit-env.in-do-not-add-C-CXX-parameters.patch | 17 ++++++++++++-----
 meta/recipes-core/gettext/gettext_1.0.bb        |  5 +++++
 2 files changed, 17 insertions(+), 5 deletions(-)

diff --git a/meta/recipes-core/gettext/gettext/0001-init-env.in-do-not-add-C-CXX-parameters.patch b/meta/recipes-core/gettext/gettext/0001-init-env.in-do-not-add-C-CXX-parameters.patch
index e59c73fb7d..67214be3e5 100644
--- a/meta/recipes-core/gettext/gettext/0001-init-env.in-do-not-add-C-CXX-parameters.patch
+++ b/meta/recipes-core/gettext/gettext/0001-init-env.in-do-not-add-C-CXX-parameters.patch
@@ -6,17 +6,22 @@ Subject: [PATCH] init-env.in: do not add C/CXX parameters
 These are taken from the cross environment and include
 sysroot paths, so are not reproducible.
 
+OBJC/OBJCFLAGS dropped as well: the recipe now exports a fully-flagged
+OBJC (same command as CC, sysroot included), which would otherwise be
+recorded here verbatim and trip the buildpaths QA check.
+
 Upstream-Status: Inappropriate [oe-core specific]
 Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
 ---
- gettext-tools/tests/init-env.in | 4 ----
- 1 file changed, 4 deletions(-)
+ gettext-tools/tests/init-env.in | 6 ------
+ 1 file changed, 6 deletions(-)
 
 diff --git a/gettext-tools/tests/init-env.in b/gettext-tools/tests/init-env.in
 index 0968388..3d9a8a5 100644
 --- a/gettext-tools/tests/init-env.in
 +++ b/gettext-tools/tests/init-env.in
-@@ -3,10 +3,6 @@ top_builddir=../..
+@@ -3,12 +3,6 @@
  
  OBJEXT="@OBJEXT@"
  EXEEXT="@EXEEXT@"
@@ -24,6 +29,8 @@ index 0968388..3d9a8a5 100644
 -CFLAGS="@CFLAGS@"
 -CXX="@CXX@"
 -CXXFLAGS="@CXXFLAGS@"
- OBJC="@OBJC@"
- OBJCFLAGS="@OBJCFLAGS@"
+-OBJC="@OBJC@"
+-OBJCFLAGS="@OBJCFLAGS@"
  CPPFLAGS="@CPPFLAGS@"
+ LDFLAGS="@LDFLAGS@"
+ LTLIBINTL="@LTLIBINTL@"
diff --git a/meta/recipes-core/gettext/gettext_1.0.bb b/meta/recipes-core/gettext/gettext_1.0.bb
index 696fcc3bb7..ce1d698260 100644
--- a/meta/recipes-core/gettext/gettext_1.0.bb
+++ b/meta/recipes-core/gettext/gettext_1.0.bb
@@ -31,6 +31,11 @@ SRC_URI:append:libc-musl = " file://0001-Ignore-failing-tests-needing-BIG5-encod
 
 inherit autotools texinfo pkgconfig ptest
 
+# configure's Objective-C probe would pick the bare ${HOST_PREFIX}cc, which
+# has no default sysroot and trips the configure-unsafe QA check; give it
+# the fully-flagged C compiler instead.
+export OBJC = "${CC}"
+
 EXTRA_OECONF += "--without-lispdir \
                  --disable-csharp \
                  --disable-libasprintf \
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 11/11] clang/llvm: Ignore tests fail with clang/llvm 23 upgrade
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (9 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 10/11] gettext: Export a fully-flagged Objective-C compiler sunilkumar.dora
@ 2026-08-30 12:58 ` sunilkumar.dora
  2026-08-30 19:53 ` [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 Khem Raj
  11 siblings, 0 replies; 30+ messages in thread
From: sunilkumar.dora @ 2026-08-30 12:58 UTC (permalink / raw)
  To: openembedded-core
  Cc: raj.khem, randy.macleod, sundeep.kokkonda, deepesh.vatharaj

From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>

Some clang/LLVM lit tests fail on target with clang/llvm 23. Exclude
them for now to keep the test results useful: one needs an od option
BusyBox does not have, two hit a known 32-bit ARM issue
(llvm/llvm-project#94741) that upstream also skips, three fail from a
lit configuration issue with a separate fix to follow, and four are
still being looked into.

Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
---
 meta/lib/oeqa/selftest/cases/clang.py | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/meta/lib/oeqa/selftest/cases/clang.py b/meta/lib/oeqa/selftest/cases/clang.py
index fe59821aff..046e46d414 100644
--- a/meta/lib/oeqa/selftest/cases/clang.py
+++ b/meta/lib/oeqa/selftest/cases/clang.py
@@ -142,6 +142,7 @@ class LLVMSelfTestSystemEmulated(ClangFamilyBase):
         "CodeGen/Thumb2/thumb2-ldm\\.ll$",
         "ExecutionEngine/JITLink/Generic/llvm-jitlink-option-show-addrs\\.test$",
         "ExecutionEngine/JITLink/Generic/sectcreate\\.test$",
+        "ExecutionEngine/JITLink/Generic/waiting-on-graph-capture-replay\\.test$",
         "ExecutionEngine/MCJIT/.*",
         "Other/can-execute\\.txt$",
         "Other/spirv-sim/.*",
@@ -157,6 +158,7 @@ class LLVMSelfTestSystemEmulated(ClangFamilyBase):
         "tools/llvm-locstats/locstats\\.ll$",
         "tools/llvm-locstats/no_scope_bytes\\.ll$",
         "tools/llvm-objcopy/DXContainer/dump-section\\.yaml$",
+        "tools/llvm-objcopy/DXContainer/dump-section-priv\\.yaml$",
         "tools/llvm-objcopy/ELF/basic-binary-copy\\.test$",
         "tools/llvm-objcopy/ELF/binary-first-seg-offset-zero\\.test$",
         "tools/llvm-objcopy/ELF/binary-no-paddr\\.test$",
@@ -248,17 +250,24 @@ class ClangSelfTestSystemEmulated(ClangFamilyBase):
         "Analysis/scan-build/silence-core-checkers\\.test$",
         "Analysis/virtualcall-fixits\\.cpp$",
         "C/C23/n3018\\.c$",
+        "ClangScanDeps/build-session-validation-outdated-module\\.c$",
+        "ClangScanDeps/build-session-validation-relocated-modules\\.c$",
+        "ClangScanDeps/diagnostics\\.c$",
         "ClangScanDeps/module.*",
         "ClangScanDeps/multiple-commands\\.c$",
         "ClangScanDeps/optimize-vfs-edgecases\\.m$",
         "ClangScanDeps/optimize-vfs-pch\\.m$",
+        "ClangScanDeps/prebuilt-modules-in-stable-dirs\\.c$",
+        "ClangScanDeps/tu-buffer\\.c$",
         "ClangScanDeps/visible-modules\\.c$",
         "ClangScanDeps/Wsystem-headers-in-module\\.c$",
         "CodeGen/builtins\\.c$",
         "CodeGen/compound-literal\\.c$",
+        "CodeGenCUDA/device-const-var-linkage\\.cu$",
         "CodeGenCUDA/static-device-var-rdc\\.cu$",
         "CodeGenCXX/int64_uint64\\.cpp$",
         "CodeGenCXX/pointers-to-data-members\\.cpp$",
+        "CodeGenCXX/template-arguments\\.cpp$",
         "CodeGenOpenCLCXX/constexpr\\.clcpp$",
         "Format/docs_updated\\.test$",
         "Frontend/rewrite-includes-bom\\.c$",
@@ -273,6 +282,7 @@ class ClangSelfTestSystemEmulated(ClangFamilyBase):
         "Preprocessor/headermap-rel2\\.c$",
         "Preprocessor/include-header-missing-in-framework-with-headermap\\.c$",
         "Preprocessor/search-path-usage\\.m$",
+        "PCH/cxx20-template-args\\.cpp$",
         "Sema/arithmetic-fence-builtin\\.c$",
         "Sema/atomic-expr\\.c$",
         "Sema/auto-type\\.c$",
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0
  2026-08-30 12:58 ` [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0 sunilkumar.dora
@ 2026-08-30 19:43   ` Khem Raj
  2026-09-01  4:07     ` [OE-core] " Dora, Sunil Kumar
  0 siblings, 1 reply; 30+ messages in thread
From: Khem Raj @ 2026-08-30 19:43 UTC (permalink / raw)
  To: sunilkumar.dora
  Cc: openembedded-core, randy.macleod, sundeep.kokkonda,
	deepesh.vatharaj

[-- Attachment #1: Type: text/plain, Size: 2264 bytes --]

On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:

> From: Sunil Dora <sunilkumar.dora@windriver.com>
>
> Each release branch of the translator only builds against the
> matching LLVM major. Move to the llvm_release_230 branch, pinned
> at the v23.1.0 tag.
>
> Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
> ---
>  ...translator_22.1.5.bb => spirv-llvm-translator_23.1.0.bb} | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>  rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb =>
> spirv-llvm-translator_23.1.0.bb} (87%)
>
> diff --git a/meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb
> b/meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb
> similarity index 87%
> rename from meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb
> rename to meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb
> index 1f80c6a27f..fd1dd9cfae 100644
> --- a/meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb
> +++ b/meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb
> @@ -5,8 +5,8 @@ LICENSE = "NCSA"
>  LIC_FILES_CHKSUM =
> "file://LICENSE.TXT;md5=47e311aa9caedd1b3abf098bd7814d1d"
>
>  # pattern: llvm_branch_200, currently there are no minor releases, so, no
> llvm_branch_201
>

  the header comment about the branch naming pattern still references the
200-era example and could be refreshed while you're here


> -SPIRV_BRANCH = "llvm_release_220"
> -SRCREV = "27afcfe385cf542197dfde8c658e1f5ff53fc2fc"
> +SPIRV_BRANCH = "llvm_release_230"
> +SRCREV = "19a29d4376ab470909ba43ca014ae668fb1156c9"
>  SRC_URI = " \
>      git://
> github.com/KhronosGroup/SPIRV-LLVM-Translator;protocol=https;branch=${SPIRV_BRANCH};tag=v${PV}
> <http://github.com/KhronosGroup/SPIRV-LLVM-Translator;protocol=https;branch=$%7BSPIRV_BRANCH%7D;tag=v$%7BPV%7D>
> \
>  "
> @@ -18,7 +18,7 @@ DEPENDS = "llvm spirv-tools spirv-headers"
>  inherit cmake pkgconfig lib_package
>
>  EXTRA_OECMAKE = "\
> -    -DBASE_LLVM_VERSION=22.1.0 \
> +    -DBASE_LLVM_VERSION=23.1.0 \
>      -DCMAKE_SKIP_BUILD_RPATH=ON \
>      -DBUILD_SHARED_LIBS=ON \
>      -DLLVM_EXTERNAL_SPIRV_HEADERS_SOURCE_DIR=${STAGING_INCDIR}/.. \
> --
> 2.43.0
>
>

[-- Attachment #2: Type: text/html, Size: 3992 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 03/11] openmp: Build via the LLVM runtimes entry point
  2026-08-30 12:58 ` [PATCH 03/11] openmp: Build via the LLVM runtimes entry point sunilkumar.dora
@ 2026-08-30 19:45   ` Khem Raj
  2026-09-01  4:33     ` [OE-core] " Dora, Sunil Kumar
  0 siblings, 1 reply; 30+ messages in thread
From: Khem Raj @ 2026-08-30 19:45 UTC (permalink / raw)
  To: sunilkumar.dora
  Cc: openembedded-core, randy.macleod, sundeep.kokkonda,
	deepesh.vatharaj

[-- Attachment #1: Type: text/plain, Size: 1975 bytes --]

On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:

> From: Sunil Dora <sunilkumar.dora@windriver.com>
>
> LLVM 23 removed the standalone build mode for openmp, so do_configure
> fails with
>
>   The legacy standalone build mode has been removed
>
> Configure it through the runtimes build with LLVM_ENABLE_RUNTIMES=openmp,
> the same way libcxx is built.
>
> The runtimes build reads LLVM_LIBDIR_SUFFIX; nothing in LLVM 23 reads
> OPENMP_LIBDIR_SUFFIX any more, so pass the standard variable like the
> other clang-family recipes do. Without it openmp installs into lib/
> while a multilib configuration packages lib64/, and do_package fails
> with "installed but not shipped" for libomp.so, libarcher.so,
> libompd.so and the cmake files.
>
> Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
> ---
>  meta/recipes-devtools/clang/openmp_git.bb | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/meta/recipes-devtools/clang/openmp_git.bb
> b/meta/recipes-devtools/clang/openmp_git.bb
> index 2ba83d48c6..90d4911623 100644
> --- a/meta/recipes-devtools/clang/openmp_git.bb
> +++ b/meta/recipes-devtools/clang/openmp_git.bb
> @@ -18,10 +18,11 @@ inherit cmake pkgconfig python3targetconfig
>  DEPENDS += "elfutils libffi clang"
>
>  EXTRA_OECMAKE += "-DCMAKE_BUILD_TYPE=RelWithDebInfo \
> -
> -DOPENMP_LIBDIR_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \
> +                  -DLLVM_ENABLE_RUNTIMES=openmp \
> +                  -DLLVM_LIBDIR_SUFFIX=${LLVM_LIBDIR_SUFFIX} \
>



The recipe keeps PACKAGECONFIG ?= "ompt-tools offloading-plugin" — under
the runtimes entry point, does offloading-plugin still do anything, or
would it now need offload added to LLVM_ENABLE_RUNTIMES?


>                "
>
> -OECMAKE_SOURCEPATH = "${S}/openmp"
> +OECMAKE_SOURCEPATH = "${S}/runtimes"
>
>  PACKAGECONFIG ?= "ompt-tools offloading-plugin"
>
> --
> 2.43.0
>
>

[-- Attachment #2: Type: text/html, Size: 3665 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23
  2026-08-30 12:58 ` [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23 sunilkumar.dora
@ 2026-08-30 19:47   ` Khem Raj
  2026-09-01  5:17     ` [OE-core] " Dora, Sunil Kumar
  0 siblings, 1 reply; 30+ messages in thread
From: Khem Raj @ 2026-08-30 19:47 UTC (permalink / raw)
  To: sunilkumar.dora
  Cc: openembedded-core, randy.macleod, sundeep.kokkonda,
	deepesh.vatharaj

[-- Attachment #1: Type: text/plain, Size: 35150 bytes --]

I wonder if each backport should have been a patch of its own. It would
make it easy to maintain of some of them get backported to later versions
of rust.

On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:

> From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>
> Backport upstream Rust commits to address build and oe-selftest
> failures introduced by the LLVM 23 upgrade.
>
> New patch:
> 0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
> The backported changes update LLVM 23 compatibility in the Rust LLVM
> wrapper and adjust affected LLVM codegen tests.
>
> Selftest Changes:
> Exclude the following Windows-specific test from oe-selftest,
> as it is not relevant.
> tests/assembly-llvm/x86_64-windows-float-abi.rs
>
> Excluded tests:
> +---------+---------+---------+
> | Before  |  After  | Skipped |
> +---------+---------+---------+
> |   43    |   44    |   +1    |
> +---------+---------+---------+
>
> Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
> ---
>  meta/lib/oeqa/selftest/cases/rust.py          |   1 +
>  ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
>  meta/recipes-devtools/rust/rust-source.inc    |   1 +
>  3 files changed, 663 insertions(+)
>  create mode 100644
> meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>
> diff --git a/meta/lib/oeqa/selftest/cases/rust.py
> b/meta/lib/oeqa/selftest/cases/rust.py
> index fa8a8c1e7c..645b5d5fbf 100644
> --- a/meta/lib/oeqa/selftest/cases/rust.py
> +++ b/meta/lib/oeqa/selftest/cases/rust.py
> @@ -83,6 +83,7 @@ class RustSelfTestSystemEmulated(OESelftestTestCase,
> OEPTestResultTestCase):
>                              'src/tools/tidy',
>
>  'tests/assembly-llvm/asm/aarch64-outline-atomics.rs',
>                              'tests/assembly-llvm/c-variadic/arm.rs',
> +
> 'tests/assembly-llvm/x86_64-windows-float-abi.rs',
>                              'tests/codegen-llvm/thread-local.rs',
>                              'tests/mir-opt/',
>                              'tests/run-make',
> diff --git
> a/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
> b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
> new file mode 100644
> index 0000000000..1e1bf089f1
> --- /dev/null
> +++
> b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
> @@ -0,0 +1,661 @@
> +Backport commits that fix build and oe-selftest failures seen with llvm 23
> +
> +Upstream-Status: Backport [
> https://github.com/rust-lang/rust/commit/b8d3a4ac9cfeb81d1e929fe6eab0af4b77ba3bb4
> ]
> +Upstream-Status: Backport [
> https://github.com/rust-lang/rust/commit/d4a24cd6e18b98326429d8c7e7bbb269da14a5aa
> ]
> +Upstream-Status: Backport [
> https://github.com/rust-lang/rust/commit/20ac2125a2142c9bde53ca06d9b3cfb6941fd437
> ]
> +Upstream-Status: Backport [
> https://github.com/rust-lang/rust/commit/2d18054569d1169bfae7ce21e5c7111f32f16774
> ]
> +Upstream-Status: Backport [
> https://github.com/rust-lang/rust/commit/e2159107f6ebc615ba6a92960d65528baf90cd35
> ]
> +Upstream-Status: Backport [
> https://github.com/rust-lang/rust/commit/283a60b64339d611b76a4ed2f9286f417b269b2f
> ]
> +Upstream-Status: Backport [
> https://github.com/rust-lang/rust/commit/61d9ba28a99f073fbeb19dbb552ddf343aef62f0
> ]
> +
> +Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> +
> +diff --git a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
> b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
> +index fe5b8edce4a..e4807f10805 100644
> +--- a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
> ++++ b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
> +@@ -49,6 +49,9 @@
> + #include "llvm/Transforms/Instrumentation/RealtimeSanitizer.h"
> + #include "llvm/Transforms/Instrumentation/ThreadSanitizer.h"
> + #include "llvm/Transforms/Scalar/AnnotationRemarks.h"
> ++#if LLVM_VERSION_GE(23, 0)
> ++#include "llvm/Transforms/Utils/AssignGUID.h"
> ++#endif
> + #include "llvm/Transforms/Utils/CanonicalizeAliases.h"
> + #include "llvm/Transforms/Utils/FunctionImportUtils.h"
> + #include "llvm/Transforms/Utils/NameAnonGlobals.h"
> +@@ -925,6 +928,9 @@
> +   if (NeedThinLTOBufferPasses) {
> +     MPM.addPass(CanonicalizeAliasesPass());
> +     MPM.addPass(NameAnonGlobalPass());
> ++#if LLVM_VERSION_GE(23, 0)
> ++    MPM.addPass(AssignGUIDPass());
> ++#endif
> +   }
> +   // For `-Copt-level=0`, and the pre-link fat/thin LTO stages.
> +   if (ThinLTOBufferRef && *ThinLTOBufferRef == nullptr) {
> +@@ -1464,6 +1470,9 @@
> +         PB.registerLoopAnalyses(LAM);
> +         PB.crossRegisterProxies(LAM, FAM, CGAM, MAM);
> +         ModulePassManager MPM;
> ++#if LLVM_VERSION_GE(23, 0)
> ++        MPM.addPass(AssignGUIDPass());
> ++#endif
> +         MPM.addPass(ThinLTOBitcodeWriterPass(OS, nullptr));
> +         MPM.run(*unwrap(M), MAM);
> +       } else {
> +diff --git a/tests/codegen-llvm/bpf-allows-unaligned.rs
> b/tests/codegen-llvm/bpf-allows-unaligned.rs
> +index c7a70d5b2e5..7e95a56d984 100644
> +--- a/tests/codegen-llvm/bpf-allows-unaligned.rs
> ++++ b/tests/codegen-llvm/bpf-allows-unaligned.rs
> +@@ -5,7 +5,7 @@
> +
> + #[no_mangle]
> + #[target_feature(enable = "allows-misaligned-mem-access")]
> +-// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg)
> unnamed_addr #0 {
> ++// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg)
> unnamed_addr #0
> + pub unsafe fn foo(arg: u8) -> u8 {
> +     arg
> + }
> +diff --git a/tests/codegen-llvm/branch-protection.rs
> b/tests/codegen-llvm/branch-protection.rs
> +index ed1cb2cd137..11847c256d6 100644
> +--- a/tests/codegen-llvm/branch-protection.rs
> ++++ b/tests/codegen-llvm/branch-protection.rs
> +@@ -22,7 +22,7 @@
> + use minicore::*;
> +
> + // A basic test function.
> +-// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]] {
> ++// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]]
> + #[no_mangle]
> + pub fn test() {}
> +
> +diff --git a/tests/codegen-llvm/frame-pointer-cli-control.rs
> b/tests/codegen-llvm/frame-pointer-cli-control.rs
> +index 911a5f03cbc..79cdfc70f1a 100644
> +--- a/tests/codegen-llvm/frame-pointer-cli-control.rs
> ++++ b/tests/codegen-llvm/frame-pointer-cli-control.rs
> +@@ -45,7 +45,7 @@
> +
> + extern crate minicore;
> +
> +-// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
> ++// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
> + #[no_mangle]
> + pub fn peach(x: u32) -> u32 {
> +     x
> +diff --git a/tests/codegen-llvm/frame-pointer.rs
> b/tests/codegen-llvm/frame-pointer.rs
> +index 1d0dd762826..a52d95a2386 100644
> +--- a/tests/codegen-llvm/frame-pointer.rs
> ++++ b/tests/codegen-llvm/frame-pointer.rs
> +@@ -18,7 +18,7 @@
> + extern crate minicore;
> + use minicore::*;
> +
> +-// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
> ++// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
> + #[no_mangle]
> + pub fn peach(x: u32) -> u32 {
> +     x
> +diff --git a/tests/codegen-llvm/gpu-convergent.rs
> b/tests/codegen-llvm/gpu-convergent.rs
> +index bb9271ab699..376d65a3d4a 100644
> +--- a/tests/codegen-llvm/gpu-convergent.rs
> ++++ b/tests/codegen-llvm/gpu-convergent.rs
> +@@ -17,7 +17,7 @@
> +     fn ext();
> + }
> +
> +-// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr
> #[[ATTR:[0-9]+]] {
> ++// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr
> #[[ATTR:[0-9]+]]
> + // CHECK: declare void @ext() unnamed_addr #[[ATTR]]
> + // CHECK: attributes #[[ATTR]] = {{.*}} convergent
> + #[no_mangle]
> +diff --git a/tests/codegen-llvm/instrument-coverage/testprog.rs
> b/tests/codegen-llvm/instrument-coverage/testprog.rs
> +index ef61ede6de8..67c49c438f9 100644
> +--- a/tests/codegen-llvm/instrument-coverage/testprog.rs
> ++++ b/tests/codegen-llvm/instrument-coverage/testprog.rs
> +@@ -101,7 +101,7 @@ fn main() {
> + // CHECK-SAME:   @__llvm_prf_nm
> + // CHECK-SAME:   section "llvm.metadata"
> +
> +-// CHECK:        define internal { {{.*}} }
> @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}} {
> ++// CHECK:        define internal { {{.*}} }
> @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}}
> + // CHECK-NEXT:   start:
> + // CHECK-NOT:    define internal
> + // CHECK:        atomicrmw add ptr
> +@@ -109,7 +109,7 @@ fn main() {
> +
> + // CHECK:        declare void @llvm.instrprof.increment(ptr, i64, i32,
> i32) #[[LLVM_INSTRPROF_INCREMENT_ATTR:[0-9]+]]
> +
> +-// WIN:          define linkonce_odr hidden i32
> @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]]
> comdat {{.*}}{
> ++// WIN:          define linkonce_odr hidden i32
> @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]]
> comdat {{.*}}
> + // WIN-NEXT:     %1 = load i32, ptr @__llvm_profile_runtime
> + // WIN-NEXT:     ret i32 %1
> + // WIN-NEXT:     }
> +diff --git a/tests/codegen-llvm/link_section.rs
> b/tests/codegen-llvm/link_section.rs
> +index f196ea86c44..61bde683c0a 100644
> +--- a/tests/codegen-llvm/link_section.rs
> ++++ b/tests/codegen-llvm/link_section.rs
> +@@ -29,7 +29,7 @@ pub enum E {
> + #[link_section = "__TEST,three"]
> + pub static VAR3: E = E::B(1.);
> +
> +-// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section
> "__TEST,four" {
> ++// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section
> "__TEST,four"
> + #[no_mangle]
> + #[link_section = "__TEST,four"]
> + pub fn fn1() {}
> +diff --git
> a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
> b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
> +index 7639ce7b104..5b1aa97ab33 100644
> +---
> a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
> ++++
> b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
> +@@ -7,21 +7,21 @@
> +
> + pub fn foo(f: fn(i32) -> i32, arg: i32) -> i32 {
> +     // CHECK-LABEL: define{{.*}}foo
> +-    // CHECK-SAME:  {{.*}}![[TYPE1:[0-9]+]]
> ++    // CHECK-SAME:  {{.*}}!type ![[TYPE1:[0-9]+]]
> +     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata
> !"_ZTSFu3i32S_E.normalized.generalized")
> +     f(arg)
> + }
> +
> + pub fn bar(f: fn(i32, i32) -> i32, arg1: i32, arg2: i32) -> i32 {
> +     // CHECK-LABEL: define{{.*}}bar
> +-    // CHECK-SAME:  {{.*}}![[TYPE2:[0-9]+]]
> ++    // CHECK-SAME:  {{.*}}!type ![[TYPE2:[0-9]+]]
> +     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata
> !"_ZTSFu3i32S_S_E.normalized.generalized")
> +     f(arg1, arg2)
> + }
> +
> + pub fn baz(f: fn(i32, i32, i32) -> i32, arg1: i32, arg2: i32, arg3: i32)
> -> i32 {
> +     // CHECK-LABEL: define{{.*}}baz
> +-    // CHECK-SAME:  {{.*}}![[TYPE3:[0-9]+]]
> ++    // CHECK-SAME:  {{.*}}!type ![[TYPE3:[0-9]+]]
> +     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata
> !"_ZTSFu3i32S_S_S_E.normalized.generalized")
> +     f(arg1, arg2, arg3)
> + }
> +diff --git a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
> b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
> +index 35317b0dd39..3df2d569f9a 100644
> +--- a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
> ++++ b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
> +@@ -72,7 +72,7 @@ pub unsafe fn some_non_zero_from_atomic_get() ->
> Option<NonZeroUsize> {
> + ///
> + /// The way we check that the LLVM IR is correct is by making sure that
> neither
> + /// `panic` nor `unreachable` is part of the LLVM IR:
> +-// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2()
> {{.*}} {
> ++// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2()
> {{.*}}
> + // CHECK-NOT: panic
> + // CHECK-NOT: unreachable
> + #[no_mangle]
> +diff --git a/tests/codegen-llvm/target-feature-negative-implication.rs
> b/tests/codegen-llvm/target-feature-negative-implication.rs
> +index a9cdca42839..376599738e5 100644
> +--- a/tests/codegen-llvm/target-feature-negative-implication.rs
> ++++ b/tests/codegen-llvm/target-feature-negative-implication.rs
> +@@ -13,7 +13,7 @@
> + #[no_mangle]
> + pub unsafe fn banana() {
> +     // CHECK-LABEL: @banana()
> +-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
> ++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
> + }
> +
> + // CHECK: attributes [[BANANAATTRS]]
> +diff --git a/tests/codegen-llvm/target-feature-overrides.rs
> b/tests/codegen-llvm/target-feature-overrides.rs
> +index 2adc8ee6f53..3bf05c7977e 100644
> +--- a/tests/codegen-llvm/target-feature-overrides.rs
> ++++ b/tests/codegen-llvm/target-feature-overrides.rs
> +@@ -23,7 +23,7 @@
> + #[no_mangle]
> + pub unsafe fn apple() -> u32 {
> +     // CHECK-LABEL: @apple()
> +-    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]] {
> ++    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]]
> +     // CHECK: {{.*}}call{{.*}}@peach
> +     peach()
> + }
> +@@ -32,7 +32,7 @@ pub unsafe fn apple() -> u32 {
> + #[no_mangle]
> + pub unsafe fn banana() -> u32 {
> +     // CHECK-LABEL: @banana()
> +-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
> ++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
> +     // COMPAT: {{.*}}call{{.*}}@peach
> +     // INCOMPAT: {{.*}}call{{.*}}@apple
> +     apple() // Compatible for inline in COMPAT revision and can't be
> inlined in INCOMPAT
> +diff --git a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
> +index ecace722e0d..279780e3a7a 100644
> +--- a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
> + // `aapcs-unwind` extern functions. `aapcs-unwind` functions MUST NOT
> have this attribute. We
> + // disable optimizations above to prevent LLVM from inferring the
> attribute.
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "aapcs" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "aapcs-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
> +index 46c08b5fc4f..1b3312839e3 100644
> +--- a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
> +@@ -7,11 +7,11 @@
> +
> + #![crate_type = "lib"]
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "C" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "C-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
> +index 8e643d6ce49..6f4eafb353c 100644
> +--- a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
> +@@ -7,11 +7,11 @@
> +
> + #![crate_type = "lib"]
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "cdecl" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "cdecl-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
> +index 7df46813ed1..51c6fd15b9c 100644
> +--- a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
> + // `fastcall-unwind` extern functions. `fastcall-unwind` functions MUST
> NOT have this attribute. We
> + // disable optimizations above to prevent LLVM from inferring the
> attribute.
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "fastcall" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "fastcall-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
> +index cc06ee12549..b5fcea52b4d 100644
> +--- a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
> + // extern functions. `stdcall-unwind` functions MUST NOT have this
> attribute. We disable
> + // optimizations above to prevent LLVM from inferring the attribute.
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "stdcall" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "stdcall-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
> +index 5f910248346..15fce95fe28 100644
> +--- a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
> +@@ -7,11 +7,11 @@
> +
> + #![crate_type = "lib"]
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "system" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "system-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
> +index 69bfaf80b4b..1293e7c0a5f 100644
> +--- a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
> + // `sysv64-unwind` extern functions. `sysv64-unwind` functions MUST NOT
> have this attribute. We
> + // disable optimizations above to prevent LLVM from inferring the
> attribute.
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "sysv64" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "sysv64-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
> +index 05f6b8b70e1..a9b6c34ee58 100644
> +--- a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
> + // `thiscall-unwind` extern functions. `thiscall-unwind` functions MUST
> NOT have this attribute. We
> + // disable optimizations above to prevent LLVM from inferring the
> attribute.
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "thiscall" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "thiscall-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
> +index d001a16b32a..8cedb55ae1d 100644
> +--- a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
> + // `vectorcall-unwind` extern functions. `vectorcall-unwind` functions
> MUST NOT have this attribute.
> + // We disable optimizations above to prevent LLVM from inferring the
> attribute.
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "vectorcall" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "vectorcall-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
> b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
> +index 257f00b54e4..2a3ad330406 100644
> +--- a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
> ++++ b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
> + // `win64-unwind` extern functions. `win64-unwind` functions MUST NOT
> have this attribute. We
> + // disable optimizations above to prevent LLVM from inferring the
> attribute.
> +
> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
> + #[no_mangle]
> + pub extern "win64" fn rust_item_that_cannot_unwind() {}
> +
> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
> + #[no_mangle]
> + pub extern "win64-unwind" fn rust_item_that_can_unwind() {}
> +
> +diff --git a/tests/assembly-llvm/slice-is_ascii.rs
> b/tests/assembly-llvm/slice-is_ascii.rs
> +index e53cd5160cf..6d660e78147 100644
> +--- a/tests/assembly-llvm/slice-is_ascii.rs
> ++++ b/tests/assembly-llvm/slice-is_ascii.rs
> +@@ -6,6 +6,11 @@
> + //@ only-x86_64
> + //@ ignore-sgx
> +
> ++// No longer optimizes as desired, tracked at:
> ++// https://github.com/rust-lang/rust/issues/154141
> ++// https://github.com/llvm/llvm-project/issues/209216
> ++//@ max-llvm-major-version: 22
> ++
> + #![feature(str_internals)]
> +
> + // CHECK-LABEL: is_ascii_simple_demo:
> +diff --git a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
> b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
> +index 40d16886c6d..d3698fda5fe 100644
> +--- a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
> ++++ b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
> +@@ -1,12 +1,16 @@
> + // verify that simd mask reductions do not introduce additional bit
> shift operations
> + //@ add-minicore
> +-//@ revisions: x86 aarch64
> ++//@ revisions: x86 aarch64-llvm22 aarch64
> + //@ [x86] compile-flags: --target=x86_64-unknown-linux-gnu -C
> llvm-args=-x86-asm-syntax=intel
> + // Set the base cpu explicitly, in case the default has been changed.
> + //@ [x86] compile-flags: -C target-cpu=x86-64
> + //@ [x86] needs-llvm-components: x86
> ++//@ [aarch64-llvm22] compile-flags: --target=aarch64-unknown-linux-gnu
> ++//@ [aarch64-llvm22] needs-llvm-components: aarch64
> ++//@ [aarch64-llvm22] max-llvm-major-version: 22
> + //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
> + //@ [aarch64] needs-llvm-components: aarch64
> ++//@ [aarch64] min-llvm-version: 23
> + //@ assembly-output: emit-asm
> + //@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
> +
> +@@ -33,12 +37,19 @@
> +     // x86-NEXT: {{cmp ax, -1|cmp eax, 65535|xor eax, 65535}}
> +     // x86-NEXT: sete al
> +     //
> ++    // aarch64-llvm22-NOT: shl
> ++    // aarch64-llvm22: cmge v0.16b, v0.16b, #0
> ++    // aarch64-llvm22-DAG: mov [[REG1:[a-z0-9]+]], #1
> ++    // aarch64-llvm22-DAG: umaxv b0, v0.16b
> ++    // aarch64-llvm22-NEXT: fmov [[REG2:[a-z0-9]+]], s0
> ++    // aarch64-llvm22-NEXT: bic w0, [[REG1]], [[REG2]]
> ++    //
> +     // aarch64-NOT: shl
> +     // aarch64: cmge v0.16b, v0.16b, #0
> +-    // aarch64-DAG: mov [[REG1:[a-z0-9]+]], #1
> +-    // aarch64-DAG: umaxv b0, v0.16b
> +-    // aarch64-NEXT: fmov [[REG2:[a-z0-9]+]], s0
> +-    // aarch64-NEXT: bic w0, [[REG1]], [[REG2]]
> ++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
> ++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
> ++    // aarch64-NEXT: cmp [[REG2]], #0
> ++    // aarch64-NEXT: cset w0, eq
> +     simd_reduce_all(m)
> + }
> +
> +@@ -50,10 +61,17 @@
> +     // x86-NEXT: test eax, eax
> +     // x86-NEXT: setne al
> +     //
> ++    // aarch64-llvm22-NOT: shl
> ++    // aarch64-llvm22: cmlt v0.16b, v0.16b, #0
> ++    // aarch64-llvm22-NEXT: umaxv b0, v0.16b
> ++    // aarch64-llvm22-NEXT: fmov [[REG:[a-z0-9]+]], s0
> ++    // aarch64-llvm22-NEXT: and w0, [[REG]], #0x1
> ++    //
> +     // aarch64-NOT: shl
> +     // aarch64: cmlt v0.16b, v0.16b, #0
> +-    // aarch64-NEXT: umaxv b0, v0.16b
> +-    // aarch64-NEXT: fmov [[REG:[a-z0-9]+]], s0
> +-    // aarch64-NEXT: and w0, [[REG]], #0x1
> ++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
> ++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
> ++    // aarch64-NEXT: cmp [[REG2]], #0
> ++    // aarch64-NEXT: cset w0, ne
> +     simd_reduce_any(m)
> + }
> +diff --git a/tests/codegen-llvm/asm/global_asm.rs
> b/tests/codegen-llvm/asm/global_asm.rs
> +index 32075daa3cf..8c1c4a3b588 100644
> +--- a/tests/codegen-llvm/asm/global_asm.rs
> ++++ b/tests/codegen-llvm/asm/global_asm.rs
> +@@ -7,10 +7,10 @@
> +
> + use std::arch::global_asm;
> +
> +-// CHECK-LABEL: foo
> + // CHECK: module asm
> ++// CHECK-LABEL: foo
> + // this regex will capture the correct unconditional branch inst.
> +-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
> ++// CHECK: "{{[[:space:]]+}}jmp baz"
> + global_asm!(
> +     r#"
> +     .global foo
> +diff --git a/tests/codegen-llvm/asm/global_asm_include.rs
> b/tests/codegen-llvm/asm/global_asm_include.rs
> +index 98be9c3e333..cad9901336b 100644
> +--- a/tests/codegen-llvm/asm/global_asm_include.rs
> ++++ b/tests/codegen-llvm/asm/global_asm_include.rs
> +@@ -7,9 +7,9 @@
> +
> + use std::arch::global_asm;
> +
> +-// CHECK-LABEL: foo
> + // CHECK: module asm
> +-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
> ++// CHECK-LABEL: foo
> ++// CHECK: "{{[[:space:]]+}}jmp baz"
> + global_asm!(include_str!("foo.s"));
> +
> + extern "C" {
> +diff --git a/tests/codegen-llvm/asm/global_asm_x2.rs
> b/tests/codegen-llvm/asm/global_asm_x2.rs
> +index 9e3a00f0680..8c6f38289de 100644
> +--- a/tests/codegen-llvm/asm/global_asm_x2.rs
> ++++ b/tests/codegen-llvm/asm/global_asm_x2.rs
> +@@ -8,12 +8,12 @@
> +
> + use core::arch::global_asm;
> +
> +-// CHECK-LABEL: foo
> + // CHECK: module asm
> +-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
> ++// CHECK-LABEL: foo
> ++// CHECK: "{{[[:space:]]+}}jmp baz"
> + // any other global_asm will be appended to this first block, so:
> + // CHECK-LABEL: bar
> +-// CHECK: module asm "{{[[:space:]]+}}jmp quux"
> ++// CHECK: "{{[[:space:]]+}}jmp quux"
> + global_asm!(
> +     r#"
> +     .global foo
> +diff --git a/tests/codegen-llvm/array-cmp.rs
> b/tests/codegen-llvm/array-cmp.rs
> +index 0106b9c15c1..5b0a802f409 100644
> +--- a/tests/codegen-llvm/array-cmp.rs
> ++++ b/tests/codegen-llvm/array-cmp.rs
> +@@ -2,6 +2,9 @@
> +
> + //@ compile-flags: -C opt-level=2
> + //@ needs-deterministic-layouts (checks depend on tuple layout)
> ++//@ revisions: LLVM22 LLVM23
> ++//@ [LLVM22] max-llvm-major-version: 22
> ++//@ [LLVM23] min-llvm-version: 23
> +
> + #![crate_type = "lib"]
> +
> +@@ -66,7 +69,8 @@ pub fn compare() -> bool {
> +     // CHECK-NEXT: br i1 %[[EQ01]], label %{{.+}}, label %[[EXIT_U]]
> +
> +     // CHECK: [[DONE]]:
> +-    // CHECK: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [ %{{.+}},
> %[[EXIT_U]] ], [ true, %[[L11]] ]
> ++    // LLVM22: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [ %{{.+}},
> %[[EXIT_U]] ], [ true, %[[L11]] ]
> ++    // LLVM23: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_U]] ], [ %{{.+}},
> %[[EXIT_S]] ], [ true, %[[L11]] ]
> +     // CHECK: ret i1 %[[RET]]
> +
> +     a <= b
> +diff --git a/tests/codegen-llvm/enum/enum-match.rs
> b/tests/codegen-llvm/enum/enum-match.rs
> +index 6d8b97328f8..a0cba452e12 100644
> +--- a/tests/codegen-llvm/enum/enum-match.rs
> ++++ b/tests/codegen-llvm/enum/enum-match.rs
> +@@ -1,5 +1,8 @@
> + //@ compile-flags: -Copt-level=1
> + //@ only-64bit
> ++//@ revisions: LLVM22 LLVM23
> ++//@ [LLVM22] max-llvm-major-version: 22
> ++//@ [LLVM23] min-llvm-version: 23
> +
> + #![crate_type = "lib"]
> + #![feature(core_intrinsics)]
> +@@ -18,8 +21,9 @@ pub enum Enum0 {
> + // CHECK-LABEL: define{{( dso_local)?}} noundef{{( range\(i8 [0-9]+,
> [0-9]+\))?}} i8 @match0(i8{{.+}}%0)
> + // CHECK-NEXT: start:
> + // CHECK-NEXT: %[[IS_B:.+]] = icmp eq i8 %0, 2
> +-// CHECK-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
> +-// CHECK-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
> ++// LLVM22-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
> ++// LLVM22-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
> ++// LLVM23-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %0
> + // CHECK-NEXT: ret i8 %[[R]]
> + #[no_mangle]
> + pub fn match0(e: Enum0) -> u8 {
> +diff --git a/tests/assembly-llvm/simd-bitmask.rs
> b/tests/assembly-llvm/simd-bitmask.rs
> +index 98f63c165f3..e8bb335c5b0 100644
> +--- a/tests/assembly-llvm/simd-bitmask.rs
> ++++ b/tests/assembly-llvm/simd-bitmask.rs
> +@@ -11,7 +11,7 @@
> + //@ [aarch64] min-llvm-version: 23
> + //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
> + //@ [aarch64] needs-llvm-components: aarch64
> +-//@ [aarch64-llvm-pre-23] ignore-llvm-version: 23 - 99
> ++//@ [aarch64-llvm-pre-23] max-llvm-major-version: 22
> + //@ [aarch64-llvm-pre-23] compile-flags:
> --target=aarch64-unknown-linux-gnu
> + //@ [aarch64-llvm-pre-23] needs-llvm-components: aarch64
> + //@ assembly-output: emit-asm
> +diff --git a/tests/codegen-llvm/array-equality.rs
> b/tests/codegen-llvm/array-equality.rs
> +index 706caebdcb6..c0f716b6067 100644
> +--- a/tests/codegen-llvm/array-equality.rs
> ++++ b/tests/codegen-llvm/array-equality.rs
> +@@ -1,5 +1,5 @@
> + //@ revisions: llvm-current llvm-next
> +-//@[llvm-current] ignore-llvm-version: 23-99
> ++//@[llvm-current] max-llvm-major-version: 22
> + //@[llvm-next] min-llvm-version: 23
> + //@ compile-flags: -Copt-level=3 -Z merge-functions=disabled
> + //@ only-x86_64
> +diff --git a/tests/ui/explicit-tail-calls/support/bystack.rs
> b/tests/ui/explicit-tail-calls/support/bystack.rs
> +index ddd9c79f5c7..c89ad194f8b 100644
> +--- a/tests/ui/explicit-tail-calls/support/bystack.rs
> ++++ b/tests/ui/explicit-tail-calls/support/bystack.rs
> +@@ -36,11 +36,11 @@
> + //@ revisions: loongarch32
> + //@[loongarch32] compile-flags: --target loongarch32-unknown-none
> + //@[loongarch32] needs-llvm-components: loongarch
> +-//@[loongarch32] ignore-llvm-version: 22 - 23
> ++//@[loongarch32] max-llvm-major-version: 21
> + //@ revisions: loongarch64
> + //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
> + //@[loongarch64] needs-llvm-components: loongarch
> +-//@[loongarch64] ignore-llvm-version: 22 - 23
> ++//@[loongarch64] max-llvm-major-version: 21
> + //@ revisions: bpf
> + //@[bpf] compile-flags: --target bpfeb-unknown-none
> + //@[bpf] needs-llvm-components: bpf
> +diff --git a/tests/ui/explicit-tail-calls/support/byval.rs
> b/tests/ui/explicit-tail-calls/support/byval.rs
> +index f451a953f2a..e6f26b9292e 100644
> +--- a/tests/ui/explicit-tail-calls/support/byval.rs
> ++++ b/tests/ui/explicit-tail-calls/support/byval.rs
> +@@ -36,11 +36,11 @@
> + //@ revisions: loongarch32
> + //@[loongarch32] compile-flags: --target loongarch32-unknown-none
> + //@[loongarch32] needs-llvm-components: loongarch
> +-//@[loongarch32] ignore-llvm-version: 22 - 23
> ++//@[loongarch32] max-llvm-major-version: 21
> + //@ revisions: loongarch64
> + //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
> + //@[loongarch64] needs-llvm-components: loongarch
> +-//@[loongarch64] ignore-llvm-version: 22 - 23
> ++//@[loongarch64] max-llvm-major-version: 21
> + //@ revisions: bpf
> + //@[bpf] compile-flags: --target bpfeb-unknown-none
> + //@[bpf] needs-llvm-components: bpf
> +diff --git a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
> b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
> +index 5834255f3d3..c3090a20e4d 100644
> +--- a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
> ++++ b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
> +@@ -14,7 +14,6 @@ pub unsafe fn foo(x: &mut Copied<Iter<'_, u32>>) -> u32
> {
> +     // CHECK-NOT: br {{.*}}
> +     // CHECK-NOT: select
> +     // CHECK: [[RET:%.*]] = load i32, ptr
> +-    // CHECK-NEXT: assume
> +-    // CHECK-NEXT: ret i32 [[RET]]
> ++    // CHECK: ret i32 [[RET]]
> +     x.next().unwrap_unchecked()
> + }
> diff --git a/meta/recipes-devtools/rust/rust-source.inc
> b/meta/recipes-devtools/rust/rust-source.inc
> index dd3e89a097..d87271b29c 100644
> --- a/meta/recipes-devtools/rust/rust-source.inc
> +++ b/meta/recipes-devtools/rust/rust-source.inc
> @@ -7,6 +7,7 @@ SRC_URI += "
> https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n
>
>  file://0001-src-core-build_steps-tool.rs-switch-off-lto-for-rust.patch;patchdir=${RUSTSRC}
> \
>
>  file://0002-Fix-rust-build-failure-with-unstable-options.patch;patchdir=${RUSTSRC}
> \
>
>  file://0003-bootstrap-skip-StdarchVerify-when-remote-testing.patch;patchdir=${RUSTSRC}
> \
> +
> file://0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch;patchdir=${RUSTSRC}
> \
>  "
>  SRC_URI[rust.sha256sum] =
> "271fa73d8174f53d713c46a8310da7bf7cfdcfb8b7cfd1c2b74b84a83ae9fb1e"
>
> --
> 2.43.0
>
>

[-- Attachment #2: Type: text/html, Size: 39418 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release
  2026-08-30 12:58 ` [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release sunilkumar.dora
@ 2026-08-30 19:53   ` Khem Raj
  2026-09-01  3:37     ` [OE-core] " Dora, Sunil Kumar
  0 siblings, 1 reply; 30+ messages in thread
From: Khem Raj @ 2026-08-30 19:53 UTC (permalink / raw)
  To: sunilkumar.dora
  Cc: openembedded-core, randy.macleod, sundeep.kokkonda,
	deepesh.vatharaj

[-- Attachment #1: Type: text/plain, Size: 143903 bytes --]

On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:

> From: Sunil Dora <sunilkumar.dora@windriver.com>
>
> Rebase the OE patch stack from 22.1.8 onto the 23.x release branch.
>
> Dropped, the fix is already in 23.1.0:
>   compiler-rt: do not use backtrace APIs on non-glibc linux
>     https://github.com/llvm/llvm-project/commit/252ad2052409
>   Rename UNUSED and UNKNOWN elements of OffloadArch enum
>     https://github.com/llvm/llvm-project/commit/82f18b02d9fe
>   libcxxabi: declare __gnu_unwind_frame in cxa_personality
>     https://github.com/llvm/llvm-project/commit/8119f1854948
>   LoopUnroll: iterate exit fold candidates in deterministic order
>     https://github.com/llvm/llvm-project/commit/965f9d87adb0
>   Prevent revisiting block when searching for noreturn
>     https://github.com/llvm/llvm-project/commit/330b40e11fd2
>
> Dropped, obsolete:
>   libcxxabi: find libunwind headers when LIBCXXABI_LIBUNWIND_INCLUDES
>     (cmake's find_path now searches the user-supplied path first)
>   compiler-rt: support a new embedded linux target
>     (only added files for the long-removed Makefile build system)
>
> Reworked for the TripleName.def triple string tables added in 23:
>   llvm/clang: insert anchor for adding OE distro vendor
>   clang/llvm: add OE specific ABI triple for N32 ABI
>
> Reworked for the restructured powerpc source lists in compiler-rt:
>   compiler-rt: enable __int128 for ppc32
>
> Newly carried, already merged in LLVM main:
>   libc: disable float16 on 32-bit x86 without SSE2
>     https://github.com/llvm/llvm-project/commit/05da143c63d3
>
> GCC 16 defines __FLT16_MANT_DIG__ when targeting i686 without SSE2,
> so the llvm-libc float16 headers that APFloat.cpp now includes fail
> to build for 32-bit x86 multilib ("SSE register return with SSE2
> disabled") without that last patch.
>
> Release notes: https://releases.llvm.org/23.1.0/docs/ReleaseNotes.html
>
> Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
> ---
>  meta/conf/distro/include/maintainers.inc      |   2 +-
>  ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
>  ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 ----
>  ...-support-a-new-embedded-linux-target.patch | 309 ------------------
>  ...env-override-of-exe-and-libdir-path.patch} |   4 +-
>  ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
>  ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
>  ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
>  ...fine-releative-gcc-installation-dir.patch} |  10 +-
>  ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
>  ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
>  ...ure-for-packages-using-find_package.patch} |  20 +-
>  ...e-dir-location-for-cross-toolchains.patch} |   4 +-
>  ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
>  ...clang-Use-python3-in-python-scripts.patch} |   6 +-
>  ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +--
>  ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
>  ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
>  ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
>  ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 ----
>  ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
>  ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
>  ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
>  ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
>  ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 ++--
>  ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
>  ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
>  ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
>  ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
>  ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
>  ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
>  ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
>  ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
>  ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
>  ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
>  ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
>  ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
>  ...> 0034-guard-clang-tools-extra-test.patch} |  47 ++-
>  ...ng-block-when-searching-for-noreturn.patch |  41 ---
>  ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 ++
>  ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 ----------------
>  ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 --
>  ...te-exit-fold-candidates-in-determini.patch |  71 ----
>  meta/recipes-devtools/clang/common-clang.inc  |   4 +-
>  meta/recipes-devtools/clang/common.inc        |  78 ++---
>  45 files changed, 302 insertions(+), 1102 deletions(-)
>  rename
> meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
>  rename
> meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
> => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
>  rename
> meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch
> => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
>  rename
> meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch
> => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
>  rename
> meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch
> => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
>  rename
> meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch
> => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch
> => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
>  rename
> meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
>  rename
> meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
>  rename
> meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch
> => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
>  rename
> meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch
> => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
>  rename
> meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch
> => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
>  rename
> meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch
> => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
>  rename
> meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
>  rename
> meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
>  rename
> meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
>  rename
> meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
>  rename
> meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
>  rename
> meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
>  rename
> meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
>  rename
> meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
> => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
>  rename
> meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
> => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
>  rename
> meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
>  rename
> meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch
> => 0034-guard-clang-tools-extra-test.patch} (83%)
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
>  create mode 100644
> meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
>
> diff --git a/meta/conf/distro/include/maintainers.inc
> b/meta/conf/distro/include/maintainers.inc
> index 2966cddc05..dde6821718 100644
> --- a/meta/conf/distro/include/maintainers.inc
> +++ b/meta/conf/distro/include/maintainers.inc
> @@ -482,7 +482,7 @@ RECIPE_MAINTAINER:pn-linux-yocto-tiny = "Bruce
> Ashfield <bruce.ashfield@gmail.co
>  RECIPE_MAINTAINER:pn-lld = "Khem Raj <raj.khem@gmail.com>"
>  RECIPE_MAINTAINER:pn-lldb = "Khem Raj <raj.khem@gmail.com>"
>  RECIPE_MAINTAINER:pn-llvm = "Khem Raj <raj.khem@gmail.com>"
> -RECIPE_MAINTAINER:pn-llvm-project-source-22.1.8 = "Khem Raj <
> raj.khem@gmail.com>"
> +RECIPE_MAINTAINER:pn-llvm-project-source-23.1.0 = "Khem Raj <
> raj.khem@gmail.com>"
>  RECIPE_MAINTAINER:pn-llvm-tblgen-native = "Khem Raj <raj.khem@gmail.com>"
>  RECIPE_MAINTAINER:pn-log4cplus = "Unassigned <unassigned@yoctoproject.org
> >"
>  RECIPE_MAINTAINER:pn-logrotate = "Yi Zhao <yi.zhao@windriver.com>"
> diff --git
> a/meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> b/meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> similarity index 90%
> rename from
> meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> rename to
> meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> index 896bbd11aa..4684fff493 100644
> ---
> a/meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> +++
> b/meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> @@ -1,4 +1,4 @@
> -From 16b03fccab20cac13065ab99f36a7f0a77a62b92 Mon Sep 17 00:00:00 2001
> +From 09798ecb4d4c7f1372e7538666bf9c5199f7ab04 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Thu, 19 May 2016 23:11:45 -0700
>  Subject: [PATCH] compiler-rt: Simplify cross-compilation. Don't use
> @@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 10 insertions(+), 1 deletion(-)
>
>  diff --git a/compiler-rt/CMakeLists.txt b/compiler-rt/CMakeLists.txt
> -index a92258ae1244..98c4e9a681d5 100644
> +index d720b86..60ac56f 100644
>  --- a/compiler-rt/CMakeLists.txt
>  +++ b/compiler-rt/CMakeLists.txt
> -@@ -109,7 +109,16 @@ if (COMPILER_RT_STANDALONE_BUILD)
> +@@ -125,7 +125,16 @@ if (COMPILER_RT_STANDALONE_BUILD)
>     set(CMAKE_CXX_EXTENSIONS NO)
>
>     if (NOT LLVM_RUNTIMES_BUILD)
> diff --git
> a/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
> b/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
> deleted file mode 100644
> index 43221274bf..0000000000
> ---
> a/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
> +++ /dev/null
> @@ -1,60 +0,0 @@
> -From 97247b6a1df63a5f930d090a3952876eb67cf6fb Mon Sep 17 00:00:00 2001
> -From: Khem Raj <raj.khem@gmail.com>
> -Date: Sun, 27 Aug 2017 10:37:49 -0700
> -Subject: [PATCH] libcxxabi: Find libunwind headers when
> - LIBCXXABI_LIBUNWIND_INCLUDES is set
> -
> -Currently, when LIBCXXABI_LIBUNWIND_INCLUDES is set via CMake arguments
> -then it ends up not searching the specified dir and unwind.h is not found
> -especially for ARM targets
> -
> -This patch makes the searching synthesized directories and then set
> -LIBCXXABI_LIBUNWIND_INCLUDES if its there in environment
> -
> -Upstream-Status: Pending
> -Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ----
> - libcxxabi/CMakeLists.txt | 15 ++++++++++-----
> - 1 file changed, 10 insertions(+), 5 deletions(-)
> -
> -diff --git a/libcxxabi/CMakeLists.txt b/libcxxabi/CMakeLists.txt
> -index 2b67c5972339..45d84b404b30 100644
> ---- a/libcxxabi/CMakeLists.txt
> -+++ b/libcxxabi/CMakeLists.txt
> -@@ -476,7 +476,7 @@ set(LIBCXXABI_LIBUNWIND_PATH
> "${LIBCXXABI_LIBUNWIND_PATH}" CACHE PATH
> -     "Specify path to libunwind source." FORCE)
> -
> - if (LIBCXXABI_USE_LLVM_UNWINDER OR LLVM_NATIVE_ARCH MATCHES ARM)
> --  find_path(LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL libunwind.h
> -+  find_path(LIBCXXABI_LIBUNWIND_INCLUDES libunwind.h
> -     PATHS ${LIBCXXABI_LIBUNWIND_INCLUDES}
> -           ${LIBCXXABI_LIBUNWIND_PATH}/include
> -           ${CMAKE_BINARY_DIR}/${LIBCXXABI_LIBUNWIND_INCLUDES}
> -@@ -487,18 +487,23 @@ if (LIBCXXABI_USE_LLVM_UNWINDER OR LLVM_NATIVE_ARCH
> MATCHES ARM)
> -     NO_CMAKE_FIND_ROOT_PATH
> -   )
> -
> --  if (LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL STREQUAL
> "LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL-NOTFOUND")
> --    set(LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL "")
> -+  if (LIBCXXABI_LIBUNWIND_INCLUDES STREQUAL
> "LIBCXXABI_LIBUNWIND_INCLUDES-NOTFOUND")
> -+    set(LIBCXXABI_LIBUNWIND_INCLUDES "")
> -   endif()
> - endif()
> -
> --if (NOT "${LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL}" STREQUAL "")
> --  include_directories("${LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL}")
> -+if (NOT "${LIBCXXABI_LIBUNWIND_INCLUDES}" STREQUAL "")
> -+  include_directories("${LIBCXXABI_LIBUNWIND_INCLUDES}")
> - endif()
> -
> - add_custom_target(cxxabi-test-depends
> -   COMMENT "Build dependencies required to run the libc++abi test suite.")
> -
> -+set(LIBCXXABI_LIBUNWIND_INCLUDES "${LIBCXXABI_LIBUNWIND_INCLUDES}" CACHE
> PATH
> -+    "Specify path to libunwind includes." FORCE)
> -+set(LIBCXXABI_LIBUNWIND_PATH "${LIBCXXABI_LIBUNWIND_PATH}" CACHE PATH
> -+    "Specify path to libunwind source." FORCE)
> -+
> - # Add source code. This also contains all of the logic for deciding
> linker flags
> - # soname, etc...
> - add_subdirectory(include)
> diff --git
> a/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
> b/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
> deleted file mode 100644
> index 5dcad6b0df..0000000000
> ---
> a/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
> +++ /dev/null
> @@ -1,309 +0,0 @@
> -From eae63772aacba29de729d9af5c52542cd8a043ee Mon Sep 17 00:00:00 2001
> -From: Khem Raj <raj.khem@gmail.com>
> -Date: Sun, 19 Apr 2015 15:16:23 -0700
> -Subject: [PATCH] compiler-rt: support a new embedded linux target
> -
> -Upstream-Status: Pending
> -Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ----
> - .../make/platform/clang_linux_embedded.mk     | 286 ++++++++++++++++++
> - .../clang_linux_embedded_test_input.c         |   0
> - 2 files changed, 286 insertions(+)
> - create mode 100644 compiler-rt/make/platform/clang_linux_embedded.mk
> - create mode 100644
> compiler-rt/make/platform/clang_linux_embedded_test_input.c
> -
> -diff --git a/compiler-rt/make/platform/clang_linux_embedded.mk
> b/compiler-rt/make/platform/clang_linux_embedded.mk
> -new file mode 100644
> -index 000000000000..d0a890075a1c
> ---- /dev/null
> -+++ b/compiler-rt/make/platform/clang_linux_embedded.mk
> -@@ -0,0 +1,286 @@
> -+# These are the functions which clang needs when it is targeting a
> previous
> -+# version of the OS. The issue is that the backend may use functions
> which were
> -+# not present in the libgcc that shipped on the platform. In such cases,
> we link
> -+# with a version of the library which contains private_extern
> definitions of all
> -+# the extra functions which might be referenced.
> -+
> -+Description := Static runtime libraries for embedded clang/Linux
> -+
> -+# A function that ensures we don't try to build for architectures that we
> -+# don't have working toolchains for.
> -+CheckArches = \
> -+  $(shell \
> -+    result=""; \
> -+    for arch in $(1); do \
> -+      if $(CC) -arch $$arch -c \
> -+        -integrated-as \
> -+        $(ProjSrcRoot)/make/platform/clang_linux_embedded_test_input.c \
> -+        -o /dev/null > /dev/null 2> /dev/null; then \
> -+        result="$$result$$arch "; \
> -+      else \
> -+      printf 1>&2 \
> -+        "warning: clang_linux_embedded.mk: dropping arch '$$arch' from
> lib '$(2)'\n"; \
> -+      fi; \
> -+    done; \
> -+    echo $$result)
> -+
> -+XCRun = \
> -+  $(shell \
> -+    result=`xcrun -find $(1) 2> /dev/null`; \
> -+    if [ "$$?" != "0" ]; then result=$(1); fi; \
> -+    echo $$result)
> -+
> -+###
> -+
> -+CC       := $(call XCRun,clang)
> -+AR       := $(call XCRun,ar)
> -+RANLIB   := $(call XCRun,ranlib)
> -+STRIP    := $(call XCRun,strip)
> -+LIPO     := $(call XCRun,lipo)
> -+DSYMUTIL := $(call XCRun,dsymutil)
> -+Configs :=
> -+UniversalArchs :=
> -+
> -+# Soft-float version of the runtime. No floating-point instructions will
> be used
> -+# and the ABI (out of necessity) passes floating values in normal
> registers:
> -+# non-VFP variant of the AAPCS.
> -+UniversalArchs.soft_static := $(call CheckArches,arm armv7m armv7em
> armv7,soft_static)
> -+Configs += $(if $(UniversalArchs.soft_static),soft_static)
> -+
> -+# Hard-float version of the runtime. On ARM VFP instructions and
> registers are
> -+# allowed, and floating point values get passed in them. VFP variant of
> the
> -+# AAPCS.
> -+UniversalArchs.hard_static := $(call CheckArches,armv7em armv7 i386
> x86_64,hard_static)
> -+Configs += $(if $(UniversalArchs.hard_static),hard_static)
> -+
> -+UniversalArchs.soft_pic := $(call CheckArches,armv6m armv7m armv7em
> armv7,soft_pic)
> -+Configs += $(if $(UniversalArchs.soft_pic),soft_pic)
> -+
> -+UniversalArchs.hard_pic := $(call CheckArches,armv7em armv7 i386
> x86_64,hard_pic)
> -+Configs += $(if $(UniversalArchs.hard_pic),hard_pic)
> -+
> -+CFLAGS := -Wall -Werror -Oz -fomit-frame-pointer -ffreestanding
> -+
> -+PIC_CFLAGS := -fPIC
> -+STATIC_CFLAGS := -static
> -+
> -+CFLAGS_SOFT := -mfloat-abi=soft
> -+CFLAGS_HARD := -mfloat-abi=hard
> -+
> -+CFLAGS_I386  := -march=pentium
> -+
> -+CFLAGS.soft_static := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_SOFT)
> -+CFLAGS.hard_static := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_HARD)
> -+CFLAGS.soft_pic    := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_SOFT)
> -+CFLAGS.hard_pic    := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_HARD)
> -+
> -+CFLAGS.soft_static.armv7 := $(CFLAGS.soft_static) $(CFLAGS_ARMV7)
> -+CFLAGS.hard_static.armv7 := $(CFLAGS.hard_static) $(CFLAGS_ARMV7)
> -+CFLAGS.soft_pic.armv7    := $(CFLAGS.soft_pic) $(CFLAGS_ARMV7)
> -+CFLAGS.hard_pic.armv7    := $(CFLAGS.hard_pic) $(CFLAGS_ARMV7)
> -+
> -+# x86 platforms ignore -mfloat-abi options and complain about doing so.
> Despite
> -+# this they're hard-float.
> -+CFLAGS.hard_static.i386   := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_I386)
> -+CFLAGS.hard_pic.i386      := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_I386)
> -+CFLAGS.hard_static.x86_64 := $(CFLAGS) $(STATIC_CFLAGS)
> -+CFLAGS.hard_pic.x86_64    := $(CFLAGS) $(PIC_CFLAGS)
> -+
> -+# Functions not wanted:
> -+#   + eprintf is obsolete anyway
> -+#   + *vfp: designed for Thumb1 CPUs with VFPv2
> -+
> -+COMMON_FUNCTIONS := \
> -+      absvdi2 \
> -+      absvsi2 \
> -+      addvdi3 \
> -+      addvsi3 \
> -+      ashldi3 \
> -+      ashrdi3 \
> -+      bswapdi2 \
> -+      bswapsi2 \
> -+      clzdi2 \
> -+      clzsi2 \
> -+      cmpdi2 \
> -+      ctzdi2 \
> -+      ctzsi2 \
> -+      divdc3 \
> -+      divdi3 \
> -+      divsc3 \
> -+      divmodsi4 \
> -+      udivmodsi4 \
> -+      do_global_dtors \
> -+      ffsdi2 \
> -+      fixdfdi \
> -+      fixsfdi \
> -+      fixunsdfdi \
> -+      fixunsdfsi \
> -+      fixunssfdi \
> -+      fixunssfsi \
> -+      floatdidf \
> -+      floatdisf \
> -+      floatundidf \
> -+      floatundisf \
> -+      gcc_bcmp \
> -+      lshrdi3 \
> -+      moddi3 \
> -+      muldc3 \
> -+      muldi3 \
> -+      mulsc3 \
> -+      mulvdi3 \
> -+      mulvsi3 \
> -+      negdi2 \
> -+      negvdi2 \
> -+      negvsi2 \
> -+      paritydi2 \
> -+      paritysi2 \
> -+      popcountdi2 \
> -+      popcountsi2 \
> -+      powidf2 \
> -+      powisf2 \
> -+      subvdi3 \
> -+      subvsi3 \
> -+      ucmpdi2 \
> -+      udiv_w_sdiv \
> -+      udivdi3 \
> -+      udivmoddi4 \
> -+      umoddi3 \
> -+      adddf3 \
> -+      addsf3 \
> -+      cmpdf2 \
> -+      cmpsf2 \
> -+      div0 \
> -+      divdf3 \
> -+      divsf3 \
> -+      divsi3 \
> -+      extendsfdf2 \
> -+      ffssi2 \
> -+      fixdfsi \
> -+      fixsfsi \
> -+      floatsidf \
> -+      floatsisf \
> -+      floatunsidf \
> -+      floatunsisf \
> -+      comparedf2 \
> -+      comparesf2 \
> -+      modsi3 \
> -+      muldf3 \
> -+      mulsf3 \
> -+      negdf2 \
> -+      negsf2 \
> -+      subdf3 \
> -+      subsf3 \
> -+      truncdfsf2 \
> -+      udivsi3 \
> -+      umodsi3 \
> -+      unorddf2 \
> -+      unordsf2
> -+
> -+ARM_FUNCTIONS := \
> -+      aeabi_cdcmpeq \
> -+      aeabi_cdrcmple \
> -+      aeabi_cfcmpeq \
> -+      aeabi_cfrcmple \
> -+      aeabi_dcmpeq \
> -+      aeabi_dcmpge \
> -+      aeabi_dcmpgt \
> -+      aeabi_dcmple \
> -+      aeabi_dcmplt \
> -+      aeabi_drsub \
> -+      aeabi_fcmpeq \
> -+      aeabi_fcmpge \
> -+      aeabi_fcmpgt \
> -+      aeabi_fcmple \
> -+      aeabi_fcmplt \
> -+      aeabi_frsub \
> -+      aeabi_idivmod \
> -+      aeabi_uidivmod \
> -+
> -+# ARM Assembly implementation which requires Thumb2 (i.e. won't work on
> v6M).
> -+THUMB2_FUNCTIONS := \
> -+      switch16 \
> -+      switch32 \
> -+      switch8 \
> -+      switchu8 \
> -+      sync_fetch_and_add_4 \
> -+      sync_fetch_and_sub_4 \
> -+      sync_fetch_and_and_4 \
> -+      sync_fetch_and_or_4 \
> -+      sync_fetch_and_xor_4 \
> -+      sync_fetch_and_nand_4 \
> -+      sync_fetch_and_max_4 \
> -+      sync_fetch_and_umax_4 \
> -+      sync_fetch_and_min_4 \
> -+      sync_fetch_and_umin_4 \
> -+      sync_fetch_and_add_8 \
> -+      sync_fetch_and_sub_8 \
> -+      sync_fetch_and_and_8 \
> -+      sync_fetch_and_or_8 \
> -+      sync_fetch_and_xor_8 \
> -+      sync_fetch_and_nand_8 \
> -+      sync_fetch_and_max_8 \
> -+      sync_fetch_and_umax_8 \
> -+      sync_fetch_and_min_8 \
> -+      sync_fetch_and_umin_8
> -+
> -+I386_FUNCTIONS :=  \
> -+      i686.get_pc_thunk.eax \
> -+      i686.get_pc_thunk.ebp \
> -+      i686.get_pc_thunk.ebx \
> -+      i686.get_pc_thunk.ecx \
> -+      i686.get_pc_thunk.edi \
> -+      i686.get_pc_thunk.edx \
> -+      i686.get_pc_thunk.esi
> -+
> -+# FIXME: Currently, compiler-rt is missing implementations for a number
> of the
> -+# functions. Filter them out for now.
> -+MISSING_FUNCTIONS := \
> -+      cmpdf2 cmpsf2 div0 \
> -+      ffssi2 \
> -+      udiv_w_sdiv unorddf2 unordsf2 bswapdi2 \
> -+      bswapsi2 \
> -+      gcc_bcmp \
> -+      do_global_dtors \
> -+      i686.get_pc_thunk.eax i686.get_pc_thunk.ebp i686.get_pc_thunk.ebx \
> -+      i686.get_pc_thunk.ecx i686.get_pc_thunk.edi i686.get_pc_thunk.edx \
> -+      i686.get_pc_thunk.esi \
> -+      aeabi_cdcmpeq aeabi_cdrcmple aeabi_cfcmpeq aeabi_cfrcmple
> aeabi_dcmpeq \
> -+      aeabi_dcmpge aeabi_dcmpgt aeabi_dcmple aeabi_dcmplt aeabi_drsub \
> -+      aeabi_fcmpeq \ aeabi_fcmpge aeabi_fcmpgt aeabi_fcmple aeabi_fcmplt
> \
> -+      aeabi_frsub aeabi_idivmod aeabi_uidivmod
> -+
> -+FUNCTIONS_ARMV6M  := $(COMMON_FUNCTIONS) $(ARM_FUNCTIONS)
> -+FUNCTIONS_ARM_ALL := $(COMMON_FUNCTIONS) $(ARM_FUNCTIONS)
> $(THUMB2_FUNCTIONS)
> -+FUNCTIONS_I386    := $(COMMON_FUNCTIONS) $(I386_FUNCTIONS)
> -+FUNCTIONS_X86_64  := $(COMMON_FUNCTIONS)
> -+
> -+FUNCTIONS_ARMV6M := \
> -+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_ARMV6M))
> -+FUNCTIONS_ARM_ALL := \
> -+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_ARM_ALL))
> -+FUNCTIONS_I386 := \
> -+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_I386))
> -+FUNCTIONS_X86_64 := \
> -+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_X86_64))
> -+
> -+FUNCTIONS.soft_static.armv6m := $(FUNCTIONS_ARMV6M)
> -+FUNCTIONS.soft_pic.armv6m    := $(FUNCTIONS_ARMV6M)
> -+
> -+FUNCTIONS.soft_static.armv7m := $(FUNCTIONS_ARM_ALL)
> -+FUNCTIONS.soft_pic.armv7m    := $(FUNCTIONS_ARM_ALL)
> -+
> -+FUNCTIONS.soft_static.armv7em := $(FUNCTIONS_ARM_ALL)
> -+FUNCTIONS.hard_static.armv7em := $(FUNCTIONS_ARM_ALL)
> -+FUNCTIONS.soft_pic.armv7em    := $(FUNCTIONS_ARM_ALL)
> -+FUNCTIONS.hard_pic.armv7em    := $(FUNCTIONS_ARM_ALL)
> -+
> -+FUNCTIONS.soft_static.armv7 := $(FUNCTIONS_ARM_ALL)
> -+FUNCTIONS.hard_static.armv7 := $(FUNCTIONS_ARM_ALL)
> -+FUNCTIONS.soft_pic.armv7    := $(FUNCTIONS_ARM_ALL)
> -+FUNCTIONS.hard_pic.armv7    := $(FUNCTIONS_ARM_ALL)
> -+
> -+FUNCTIONS.hard_static.i386 := $(FUNCTIONS_I386)
> -+FUNCTIONS.hard_pic.i386    := $(FUNCTIONS_I386)
> -+
> -+FUNCTIONS.hard_static.x86_64 := $(FUNCTIONS_X86_64)
> -+FUNCTIONS.hard_pic.x86_64    := $(FUNCTIONS_X86_64)
> -diff --git a/compiler-rt/make/platform/clang_linux_embedded_test_input.c
> b/compiler-rt/make/platform/clang_linux_embedded_test_input.c
> -new file mode 100644
> -index 000000000000..e69de29bb2d1
> diff --git
> a/meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
> b/meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
> similarity index 96%
> rename from
> meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
> rename to
> meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
> index 3c7c274693..583718c6ee 100644
> ---
> a/meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
> +++
> b/meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
> @@ -1,4 +1,4 @@
> -From d13464858866ff3c0026294d6842f74a11a0d625 Mon Sep 17 00:00:00 2001
> +From 9aa64eaa942dad120bc6baaf17d6d859049f9de9 Mon Sep 17 00:00:00 2001
>  From: Martin Kelly <mkelly@xevo.com>
>  Date: Fri, 19 May 2017 00:22:57 -0700
>  Subject: [PATCH] llvm: allow env override of exe and libdir path
> @@ -19,7 +19,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 19 insertions(+), 6 deletions(-)
>
>  diff --git a/llvm/tools/llvm-config/llvm-config.cpp
> b/llvm/tools/llvm-config/llvm-config.cpp
> -index 24ea264419af..0a3f51ae2b83 100644
> +index 76aa9f8..64795e9 100644
>  --- a/llvm/tools/llvm-config/llvm-config.cpp
>  +++ b/llvm/tools/llvm-config/llvm-config.cpp
>  @@ -248,6 +248,13 @@ Typical components:\n\
> diff --git
> a/meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch
> b/meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
> similarity index 87%
> rename from
> meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch
> rename to
> meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
> index e4636d30d1..d68dc94b03 100644
> ---
> a/meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch
> +++
> b/meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
> @@ -1,4 +1,4 @@
> -From 7a12ad3232dd6881ca40d94277ca8064a12d9df6 Mon Sep 17 00:00:00 2001
> +From 6d26dbc005701acc1dbbd9e05e8596328a7d58f1 Mon Sep 17 00:00:00 2001
>  From: Dan McGregor <dan.mcgregor@usask.ca>
>  Date: Wed, 26 Apr 2017 20:29:41 -0600
>  Subject: [PATCH] clang: driver: Check sysroot for ldso path
> @@ -17,10 +17,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 21 insertions(+), 1 deletion(-)
>
>  diff --git a/clang/lib/Driver/ToolChains/Linux.cpp
> b/clang/lib/Driver/ToolChains/Linux.cpp
> -index d525b417b4ea..1c31901ade74 100644
> +index 8d30a5e..1958c64 100644
>  --- a/clang/lib/Driver/ToolChains/Linux.cpp
>  +++ b/clang/lib/Driver/ToolChains/Linux.cpp
> -@@ -630,8 +630,12 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -645,8 +645,12 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>           Triple.getEnvironment() == llvm::Triple::GNUEABIHFT64 ||
>           tools::arm::getARMFloatABI(*this, Args) ==
> tools::arm::FloatABI::Hard;
>
> @@ -34,7 +34,7 @@ index d525b417b4ea..1c31901ade74 100644
>       break;
>     }
>     case llvm::Triple::loongarch32: {
> -@@ -685,11 +689,19 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -700,11 +704,19 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>       LibDir = "lib64";
>       Loader =
>           (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" :
> "ld64.so.1";
> @@ -53,8 +53,8 @@ index d525b417b4ea..1c31901ade74 100644
>  +    }
>       break;
>     case llvm::Triple::riscv32:
> -   case llvm::Triple::riscv64: {
> -@@ -707,6 +719,10 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +   case llvm::Triple::riscv64:
> +@@ -724,6 +736,10 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>     case llvm::Triple::sparcv9:
>       LibDir = "lib64";
>       Loader = "ld-linux.so.2";
> @@ -65,7 +65,7 @@ index d525b417b4ea..1c31901ade74 100644
>       break;
>     case llvm::Triple::systemz:
>       LibDir = "lib";
> -@@ -721,6 +737,10 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -738,6 +754,10 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>
>       LibDir = X32 ? "libx32" : "lib64";
>       Loader = X32 ? "ld-linux-x32.so.2" : "ld-linux-x86-64.so.2";
> diff --git
> a/meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> b/meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> similarity index 86%
> rename from
> meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> rename to
> meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> index 0269dece67..1ba19bb4cd 100644
> ---
> a/meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> +++
> b/meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> @@ -1,4 +1,4 @@
> -From 19b8ca2e1aa536e7d7f7eb379fc4e4d6f1efd07a Mon Sep 17 00:00:00 2001
> +From 64a5c3e2680fb2a04ecba015af8eb5049c4840e1 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Thu, 19 May 2016 21:11:06 -0700
>  Subject: [PATCH] clang: Driver/tools.cpp: Add -lssp_nonshared on musl
> @@ -14,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 6 insertions(+)
>
>  diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp
> b/clang/lib/Driver/ToolChains/Gnu.cpp
> -index cb6a9b242421..8f126474b7d1 100644
> +index 24076d8..a7a64fc 100644
>  --- a/clang/lib/Driver/ToolChains/Gnu.cpp
>  +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
> -@@ -539,6 +539,12 @@ void
> tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
> +@@ -537,6 +537,12 @@ void
> tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
>         if (IsIAMCU)
>           CmdArgs.push_back("-lgloss");
>
> diff --git
> a/meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch
> b/meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
> similarity index 81%
> rename from
> meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch
> rename to
> meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
> index 321de79c78..0de2208a0f 100644
> ---
> a/meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch
> +++
> b/meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
> @@ -1,4 +1,4 @@
> -From 1746960b385afbc9e8e355a3b7c66b43c946451b Mon Sep 17 00:00:00 2001
> +From e6285791435950771c13b442319efdcd6a21d81e Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Thu, 16 Mar 2017 09:02:13 -0700
>  Subject: [PATCH] clang: Prepend trailing '/' to sysroot
> @@ -25,12 +25,12 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
>  diff --git a/clang/lib/Driver/ToolChains/Linux.cpp
> b/clang/lib/Driver/ToolChains/Linux.cpp
> -index 1c31901ade74..f7f096c1ac0a 100644
> +index 1958c64..cb2b227 100644
>  --- a/clang/lib/Driver/ToolChains/Linux.cpp
>  +++ b/clang/lib/Driver/ToolChains/Linux.cpp
> -@@ -235,7 +235,7 @@ Linux::Linux(const Driver &D, const llvm::Triple
> &Triple, const ArgList &Args)
> -   Multilibs = GCCInstallation.getMultilibs();
> -   SelectedMultilibs.assign({GCCInstallation.getMultilib()});
> +@@ -238,7 +238,7 @@ Linux::Linux(const Driver &D, const llvm::Triple
> &Triple, const ArgList &Args)
> +   loadMultilibsFromYAML(Args, D);
> +
>     llvm::Triple::ArchType Arch = Triple.getArch();
>  -  std::string SysRoot = computeSysRoot();
>  +  std::string SysRoot = computeSysRoot() + "/";
> diff --git
> a/meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch
> b/meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
> similarity index 94%
> rename from
> meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch
> rename to
> meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
> index 38470e9834..427842a07a 100644
> ---
> a/meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch
> +++
> b/meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
> @@ -1,4 +1,4 @@
> -From bfba4232621e151cfc5dcb16ce5bf661f8c3d8f8 Mon Sep 17 00:00:00 2001
> +From 04e0958fea64ebc9c89c0a6c147e8806a87727bd Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Sat, 20 Mar 2021 16:09:16 -0700
>  Subject: [PATCH] clang: Define / releative gcc installation dir
> @@ -61,7 +61,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 14 insertions(+), 8 deletions(-)
>
>  diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp
> b/clang/lib/Driver/ToolChains/Gnu.cpp
> -index 8f126474b7d1..c80980a7fb09 100644
> +index a7a64fc..f44663f 100644
>  --- a/clang/lib/Driver/ToolChains/Gnu.cpp
>  +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
>  @@ -18,6 +18,7 @@
> @@ -72,7 +72,7 @@ index 8f126474b7d1..c80980a7fb09 100644
>   #include "clang/Driver/Driver.h"
>   #include "clang/Driver/MultilibBuilder.h"
>   #include "clang/Driver/Tool.h"
> -@@ -2847,6 +2848,7 @@ void
> Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
> +@@ -2869,6 +2870,7 @@ void
> Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
>       const llvm::Triple &TargetTriple, const ArgList &Args,
>       const std::string &LibDir, StringRef CandidateTriple,
>       bool NeedsBiarchSuffix, bool GCCDirExists, bool GCCCrossDirExists) {
> @@ -80,7 +80,7 @@ index 8f126474b7d1..c80980a7fb09 100644
>     // Locations relative to the system lib directory where GCC's
> triple-specific
>     // directories might reside.
>     struct GCCLibSuffix {
> -@@ -2858,19 +2860,20 @@ void
> Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
> +@@ -2880,19 +2882,20 @@ void
> Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
>       // Whether this library suffix is relevant for the triple.
>       bool Active;
>     } Suffixes[] = {
> @@ -108,7 +108,7 @@ index 8f126474b7d1..c80980a7fb09 100644
>
>     SmallVector<GCCInstallCandidate, 3> Installations;
>     for (auto &Suffix : Suffixes) {
> -@@ -3273,8 +3276,11 @@ Generic_GCC::addLibCxxIncludePaths(const
> llvm::opt::ArgList &DriverArgs,
> +@@ -3297,8 +3300,11 @@ Generic_GCC::addLibCxxIncludePaths(const
> llvm::opt::ArgList &DriverArgs,
>     // incompatible with the NDK libraries.
>     SmallString<128> DriverIncludeDir(getDriver().Dir);
>     llvm::sys::path::append(DriverIncludeDir, "..", "include");
> diff --git
> a/meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> b/meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> similarity index 86%
> rename from
> meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> rename to
> meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> index b338d0f570..e07f004fb4 100644
> ---
> a/meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> +++
> b/meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> @@ -1,8 +1,8 @@
> -From 03875620d0172a7c07e3cdc607a6877b06a130e9 Mon Sep 17 00:00:00 2001
> +From f64b2adab7e4c515aa1e082054ad4514898e2d5d Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Wed, 31 Jul 2019 22:51:39 -0700
> -Subject: [PATCH] clang: Add -lpthread and -ldl along with -lunwind for
> static
> - linking
> +Subject: [PATCH] clang: Add -lpthread and -ldl along with -lunwind for
> + static linking
>
>  When doing static liking with --unwindlib=libunwind -static we encounter
>  undefined symbols
> @@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 2 insertions(+)
>
>  diff --git a/clang/lib/Driver/ToolChains/CommonArgs.cpp
> b/clang/lib/Driver/ToolChains/CommonArgs.cpp
> -index 10a1a412eea0..a217897610c3 100644
> +index 08c0695..362e7ca 100644
>  --- a/clang/lib/Driver/ToolChains/CommonArgs.cpp
>  +++ b/clang/lib/Driver/ToolChains/CommonArgs.cpp
> -@@ -2415,6 +2415,8 @@ static void AddUnwindLibrary(const ToolChain &TC,
> const Driver &D,
> +@@ -2484,6 +2484,8 @@ static void AddUnwindLibrary(const ToolChain &TC,
> const Driver &D,
>           CmdArgs.push_back("-lunwind");
>       } else if (LGT == LibGccType::StaticLibGcc) {
>         CmdArgs.push_back("-l:libunwind.a");
> diff --git
> a/meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch
> b/meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
> similarity index 91%
> rename from
> meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch
> rename to
> meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
> index ba6a5c1510..c9764c70e9 100644
> ---
> a/meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch
> +++
> b/meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
> @@ -1,4 +1,4 @@
> -From ea4326b11976e48dde6d99605ac24df048cd3b10 Mon Sep 17 00:00:00 2001
> +From a4a94de113dce4cf88c05bf0d5628a902ed93ff3 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Mon, 18 Nov 2019 17:00:29 -0800
>  Subject: [PATCH] Check for atomic<double> intrinsics
> @@ -16,7 +16,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
>  diff --git a/llvm/cmake/modules/CheckAtomic.cmake
> b/llvm/cmake/modules/CheckAtomic.cmake
> -index f11cadf39ff6..80a18a92956a 100644
> +index f11cadf..80a18a9 100644
>  --- a/llvm/cmake/modules/CheckAtomic.cmake
>  +++ b/llvm/cmake/modules/CheckAtomic.cmake
>  @@ -30,10 +30,11 @@ function(check_working_cxx_atomics64 varname)
> diff --git
> a/meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch
> b/meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
> similarity index 89%
> rename from
> meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch
> rename to
> meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
> index 946eb1661f..2a3744f225 100644
> ---
> a/meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch
> +++
> b/meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
> @@ -1,4 +1,4 @@
> -From dc281691e778a61cc14bca4eb187792d2ffb384c Mon Sep 17 00:00:00 2001
> +From d373417d4724071c98f95d17c88cc78e9dc1c241 Mon Sep 17 00:00:00 2001
>  From: Ovidiu Panait <ovidiu.panait@windriver.com>
>  Date: Fri, 31 Jan 2020 10:56:11 +0200
>  Subject: [PATCH] cmake: Fix configure for packages using find_package()
> @@ -31,7 +31,7 @@ Signed-off-by: Ovidiu Panait <
> ovidiu.panait@windriver.com>
>   3 files changed, 2 insertions(+), 15 deletions(-)
>
>  diff --git a/clang/cmake/modules/AddClang.cmake
> b/clang/cmake/modules/AddClang.cmake
> -index 4059fc3e986c..44d43aa8f25b 100644
> +index e2112d7..f51983d 100644
>  --- a/clang/cmake/modules/AddClang.cmake
>  +++ b/clang/cmake/modules/AddClang.cmake
>  @@ -182,7 +182,6 @@ macro(add_clang_tool name)
> @@ -51,10 +51,10 @@ index 4059fc3e986c..44d43aa8f25b 100644
>     endif()
>     set_target_properties(${name} PROPERTIES XCODE_GENERATE_SCHEME ON)
>  diff --git a/llvm/cmake/modules/AddLLVM.cmake
> b/llvm/cmake/modules/AddLLVM.cmake
> -index d938214f9d0d..4816f2127e14 100644
> +index a267166..09ff2af 100644
>  --- a/llvm/cmake/modules/AddLLVM.cmake
>  +++ b/llvm/cmake/modules/AddLLVM.cmake
> -@@ -1485,7 +1485,6 @@ macro(llvm_add_tool project name)
> +@@ -1625,7 +1625,6 @@ macro(llvm_add_tool project name)
>         if( LLVM_BUILD_TOOLS )
>           get_target_export_arg(${name} ${project} export_to_llvmexports)
>           install(TARGETS ${name}
> @@ -62,7 +62,7 @@ index d938214f9d0d..4816f2127e14 100644
>                   RUNTIME DESTINATION ${${project}_TOOLS_INSTALL_DIR}
>                   COMPONENT ${name})
>           if (LLVM_ENABLE_PDB)
> -@@ -1501,10 +1500,8 @@ macro(llvm_add_tool project name)
> +@@ -1641,10 +1640,8 @@ macro(llvm_add_tool project name)
>           endif()
>         endif()
>       endif()
> @@ -75,7 +75,7 @@ index d938214f9d0d..4816f2127e14 100644
>     endif()
>     get_subproject_title(subproject_title)
>     set_target_properties(${name} PROPERTIES FOLDER
> "${subproject_title}/Tools")
> -@@ -1559,7 +1556,6 @@ macro(add_llvm_utility name)
> +@@ -1699,7 +1696,6 @@ macro(add_llvm_utility name)
>       if (LLVM_INSTALL_UTILS AND LLVM_BUILD_UTILS)
>         get_target_export_arg(${name} LLVM export_to_llvmexports)
>         install(TARGETS ${name}
> @@ -83,7 +83,7 @@ index d938214f9d0d..4816f2127e14 100644
>                 RUNTIME DESTINATION ${LLVM_UTILS_INSTALL_DIR}
>                 COMPONENT ${name})
>         if (LLVM_ENABLE_PDB)
> -@@ -1573,7 +1569,6 @@ macro(add_llvm_utility name)
> +@@ -1713,7 +1709,6 @@ macro(add_llvm_utility name)
>                                    DEPENDS ${name}
>                                    COMPONENT ${name})
>         endif()
> @@ -92,10 +92,10 @@ index d938214f9d0d..4816f2127e14 100644
>         set_property(GLOBAL APPEND PROPERTY LLVM_EXPORTS_BUILDTREE_ONLY
> ${name})
>       endif()
>  diff --git a/llvm/cmake/modules/TableGen.cmake
> b/llvm/cmake/modules/TableGen.cmake
> -index 84c03cd6432e..72da60ce3ca1 100644
> +index 397089a..5240962 100644
>  --- a/llvm/cmake/modules/TableGen.cmake
>  +++ b/llvm/cmake/modules/TableGen.cmake
> -@@ -237,12 +237,7 @@ macro(add_tablegen target project)
> +@@ -239,12 +239,7 @@ macro(add_tablegen target project)
>
>     if (ADD_TABLEGEN_DESTINATION AND NOT LLVM_INSTALL_TOOLCHAIN_ONLY AND
>         (LLVM_BUILD_UTILS OR ${target} IN_LIST
> LLVM_DISTRIBUTION_COMPONENTS))
> @@ -108,7 +108,7 @@ index 84c03cd6432e..72da60ce3ca1 100644
>               COMPONENT ${target}
>               RUNTIME DESTINATION "${ADD_TABLEGEN_DESTINATION}")
>       if(NOT LLVM_ENABLE_IDE)
> -@@ -253,7 +248,6 @@ macro(add_tablegen target project)
> +@@ -255,7 +250,6 @@ macro(add_tablegen target project)
>     endif()
>     if(ADD_TABLEGEN_EXPORT)
>       string(TOUPPER ${ADD_TABLEGEN_EXPORT} export_upper)
> diff --git
> a/meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> b/meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> similarity index 95%
> rename from
> meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> rename to
> meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> index 72b989c0a2..df6c44bca1 100644
> ---
> a/meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> +++
> b/meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> @@ -1,4 +1,4 @@
> -From 248a51bece02c199d0f84d14fa7e2e2379c592a0 Mon Sep 17 00:00:00 2001
> +From d03df63cfd772452b5b7c8ddb587f576f054b004 Mon Sep 17 00:00:00 2001
>  From: Jim Broadus <jbroadus@xevo.com>
>  Date: Thu, 26 Mar 2020 16:05:53 -0700
>  Subject: [PATCH] clang: Fix resource dir location for cross toolchains
> @@ -21,7 +21,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 8 insertions(+), 1 deletion(-)
>
>  diff --git a/clang/lib/Options/OptionUtils.cpp
> b/clang/lib/Options/OptionUtils.cpp
> -index e5aefa012f67..7c1b657ce2c1 100644
> +index 77f8955..62bb694 100644
>  --- a/clang/lib/Options/OptionUtils.cpp
>  +++ b/clang/lib/Options/OptionUtils.cpp
>  @@ -213,6 +213,7 @@ std::string clang::GetResourcesPath(StringRef
> BinaryPath) {
> diff --git
> a/meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> b/meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> similarity index 88%
> rename from
> meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> rename to
> meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> index 725d10a2a7..29d7a6d6bc 100644
> ---
> a/meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> +++
> b/meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> @@ -1,8 +1,8 @@
> -From b3eea8bcdb792a7b19b879c76eac64f36d1fe012 Mon Sep 17 00:00:00 2001
> +From 75e6420bd7f45f1b60a856d51866e22d83cf55b0 Mon Sep 17 00:00:00 2001
>  From: Oleksandr Ocheretnyi <oocheret@cisco.com>
>  Date: Wed, 15 Apr 2020 00:08:39 +0300
> -Subject: [PATCH] clang: driver: Add dyld-prefix when checking sysroot for
> ldso
> - path
> +Subject: [PATCH] clang: driver: Add dyld-prefix when checking sysroot
> + for ldso path
>
>   * the dyld-prefix shall be taken into account when the default
>     path for the dynamic linker has to be checked.
> @@ -19,10 +19,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 10 insertions(+), 10 deletions(-)
>
>  diff --git a/clang/lib/Driver/ToolChains/Linux.cpp
> b/clang/lib/Driver/ToolChains/Linux.cpp
> -index f7f096c1ac0a..7b608a84a66e 100644
> +index cb2b227..c2ac9b6 100644
>  --- a/clang/lib/Driver/ToolChains/Linux.cpp
>  +++ b/clang/lib/Driver/ToolChains/Linux.cpp
> -@@ -632,8 +632,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -647,8 +647,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>
>       Loader = HF ? "ld-linux-armhf.so.3" : "ld-linux.so.3";
>       LibDir = "lib32";
> @@ -33,7 +33,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
>           LibDir = "lib";
>       }
>       break;
> -@@ -689,8 +689,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -704,8 +704,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>       LibDir = "lib64";
>       Loader =
>           (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" :
> "ld64.so.1";
> @@ -44,7 +44,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
>           LibDir = "lib";
>       }
>       break;
> -@@ -698,8 +698,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -713,8 +713,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>       LibDir = "lib64";
>       Loader =
>           (tools::ppc::hasPPCAbiArg(Args, "elfv1")) ? "ld64.so.1" :
> "ld64.so.2";
> @@ -55,7 +55,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
>           LibDir = "lib";
>       }
>       break;
> -@@ -719,8 +719,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -736,8 +736,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>     case llvm::Triple::sparcv9:
>       LibDir = "lib64";
>       Loader = "ld-linux.so.2";
> @@ -66,7 +66,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
>           LibDir = "lib";
>       }
>       break;
> -@@ -737,8 +737,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
> +@@ -754,8 +754,8 @@ std::string Linux::getDynamicLinker(const ArgList
> &Args) const {
>
>       LibDir = X32 ? "libx32" : "lib64";
>       Loader = X32 ? "ld-linux-x32.so.2" : "ld-linux-x86-64.so.2";
> diff --git
> a/meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch
> b/meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
> similarity index 90%
> rename from
> meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch
> rename to
> meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
> index e29d23cab2..5b0a0b3431 100644
> ---
> a/meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch
> +++
> b/meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
> @@ -1,4 +1,4 @@
> -From 17e1af5e12a01296d2c032a768569d4d8b06505b Mon Sep 17 00:00:00 2001
> +From bc161f33adb168a0a1614d38eb84190c3f690000 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Wed, 14 Oct 2020 22:19:57 -0700
>  Subject: [PATCH] clang: Use python3 in python scripts
> @@ -14,7 +14,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   2 files changed, 2 insertions(+), 2 deletions(-)
>
>  diff --git
> a/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
> b/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
> -index 49a1b1493264..6158876d15f7 100755
> +index 49a1b14..6158876 100755
>  ---
> a/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
>  +++
> b/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
>  @@ -1,4 +1,4 @@
> @@ -24,7 +24,7 @@ index 49a1b1493264..6158876d15f7 100755
>   # =- run-find-all-symbols.py - Parallel find-all-symbols runner -*-
> python  -*-=#
>   #
>  diff --git a/clang/tools/scan-view/bin/scan-view
> b/clang/tools/scan-view/bin/scan-view
> -index d01aebb4029a..f3375804654d 100755
> +index d01aebb..f337580 100755
>  --- a/clang/tools/scan-view/bin/scan-view
>  +++ b/clang/tools/scan-view/bin/scan-view
>  @@ -1,4 +1,4 @@
> diff --git
> a/meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> b/meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> similarity index 91%
> rename from
> meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> rename to
> meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> index 674a3b264e..aba7488323 100644
> ---
> a/meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> +++
> b/meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> @@ -1,7 +1,8 @@
> -From 259d8eb2ed82c9248387a3cbb1befee358ecbb8e Mon Sep 17 00:00:00 2001
> +From 12fbb32963d7aad6c0d5a0ca5fc0f536f1a9b4fe Mon Sep 17 00:00:00 2001
>  From: Hongxu Jia <hongxu.jia@windriver.com>
>  Date: Mon, 25 Jan 2021 16:14:35 +0800
> -Subject: [PATCH] llvm/clang: Insert anchor for adding OE distro vendor
> names
> +Subject: [PATCH] llvm/clang: Insert anchor for adding OE distro vendor
> + names
>  MIME-Version: 1.0
>  Content-Type: text/plain; charset=UTF-8
>  Content-Transfer-Encoding: 8bit
> @@ -99,11 +100,11 @@ Signed-off-by: João Marcos Costa <
> joaomarcos.costa@bootlin.com>
>   clang/lib/Driver/Distro.cpp           | 1 +
>   clang/lib/Driver/ToolChains/Gnu.cpp   | 1 +
>   clang/lib/Driver/ToolChains/Linux.cpp | 2 ++
> - llvm/lib/TargetParser/Triple.cpp      | 2 +-
> - 5 files changed, 7 insertions(+), 1 deletion(-)
> + llvm/lib/TargetParser/Triple.cpp      | 1 +
> + 5 files changed, 7 insertions(+)
>
>  diff --git a/clang/include/clang/Driver/Distro.h
> b/clang/include/clang/Driver/Distro.h
> -index 0e17b30eb..b449a62dc 100644
> +index aa4b3e1..2d77a2b 100644
>  --- a/clang/include/clang/Driver/Distro.h
>  +++ b/clang/include/clang/Driver/Distro.h
>  @@ -45,6 +45,7 @@ public:
> @@ -114,7 +115,7 @@ index 0e17b30eb..b449a62dc 100644
>       OpenSUSE,
>       UbuntuQuantal,
>       UbuntuRaring,
> -@@ -132,6 +133,7 @@ public:
> +@@ -133,6 +134,7 @@ public:
>
>     bool IsGentoo() const { return DistroVal == Gentoo; }
>
> @@ -123,7 +124,7 @@ index 0e17b30eb..b449a62dc 100644
>   };
>
>  diff --git a/clang/lib/Driver/Distro.cpp b/clang/lib/Driver/Distro.cpp
> -index df10458d0..61dc127a4 100644
> +index 585497e..3b58ac7 100644
>  --- a/clang/lib/Driver/Distro.cpp
>  +++ b/clang/lib/Driver/Distro.cpp
>  @@ -43,6 +43,7 @@ static Distro::DistroType
> DetectOsRelease(llvm::vfs::FileSystem &VFS) {
> @@ -135,10 +136,10 @@ index df10458d0..61dc127a4 100644
>     return Version;
>   }
>  diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp
> b/clang/lib/Driver/ToolChains/Gnu.cpp
> -index c80980a7f..80fd8058b 100644
> +index f44663f..73ff1f4 100644
>  --- a/clang/lib/Driver/ToolChains/Gnu.cpp
>  +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
> -@@ -2370,6 +2370,7 @@ void
> Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
> +@@ -2371,6 +2371,7 @@ void
> Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
>         "x86_64-pc-linux-gnu",    "x86_64-redhat-linux6E",
>         "x86_64-redhat-linux",    "x86_64-suse-linux",
>         "x86_64-manbo-linux-gnu", "x86_64-slackware-linux",
> @@ -147,7 +148,7 @@ index c80980a7f..80fd8058b 100644
>     static const char *const X32Triples[] = {"x86_64-linux-gnux32",
>                                              "x86_64-pc-linux-gnux32"};
>  diff --git a/clang/lib/Driver/ToolChains/Linux.cpp
> b/clang/lib/Driver/ToolChains/Linux.cpp
> -index 7b608a84a..585a86a2d 100644
> +index c2ac9b6..3231f36 100644
>  --- a/clang/lib/Driver/ToolChains/Linux.cpp
>  +++ b/clang/lib/Driver/ToolChains/Linux.cpp
>  @@ -45,6 +45,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
> @@ -167,18 +168,14 @@ index 7b608a84a..585a86a2d 100644
>     case llvm::Triple::aarch64:
>       if (IsAndroid)
>  diff --git a/llvm/lib/TargetParser/Triple.cpp
> b/llvm/lib/TargetParser/Triple.cpp
> -index a4f9dd42c..86b74451e 100644
> +index 356782c..883e654 100644
>  --- a/llvm/lib/TargetParser/Triple.cpp
>  +++ b/llvm/lib/TargetParser/Triple.cpp
> -@@ -702,7 +702,7 @@ static Triple::VendorType parseVendor(StringRef
> VendorName) {
> -       .Case("suse", Triple::SUSE)
> -       .Case("oe", Triple::OpenEmbedded)
> -       .Case("intel", Triple::Intel)
> --      .Case("meta", Triple::Meta)
> -+      .Case("meta", Triple::Meta) //CLANG_EXTRA_OE_VENDORS_CASES
> +@@ -741,6 +741,7 @@ static Triple::VendorType parseVendor(StringRef
> VendorName) {
> + #define TRIPLE_VENDOR(Enum, Name) .Case(Name, Triple::Enum)
> + #define TRIPLE_VENDOR_ALIAS(Enum, AliasName) .Case(AliasName,
> Triple::Enum)
> + #include "llvm/TargetParser/TripleName.def"
> ++      //CLANG_EXTRA_OE_VENDORS_CASES
>         .Default(Triple::UnknownVendor);
>   }
>
> ---
> -2.39.5
> -
> diff --git
> a/meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> b/meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> similarity index 86%
> rename from
> meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> rename to
> meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> index 786ff426d3..d54859c338 100644
> ---
> a/meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> +++
> b/meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> @@ -1,7 +1,8 @@
> -From 6839ba1413cf09eb14a24eeda44fb02c1c6809e1 Mon Sep 17 00:00:00 2001
> +From 0a569622e3ebdb2ebd1a2a4f9553161c1bd188d8 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Wed, 19 May 2021 17:56:03 -0700
> -Subject: [PATCH] clang: Fix x86 triple for non-debian multiarch linux
> distros
> +Subject: [PATCH] clang: Fix x86 triple for non-debian multiarch linux
> + distros
>
>  OpenEmbedded does not hardcode mutli-arch like debian therefore ensure
>  that it still uses the proper tuple
> @@ -13,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
>  diff --git a/clang/lib/Driver/ToolChains/Linux.cpp
> b/clang/lib/Driver/ToolChains/Linux.cpp
> -index 4a0adedce09a..9fed904c05c2 100644
> +index 3231f36..41e0017 100644
>  --- a/clang/lib/Driver/ToolChains/Linux.cpp
>  +++ b/clang/lib/Driver/ToolChains/Linux.cpp
> -@@ -227,8 +227,9 @@ Linux::Linux(const Driver &D, const llvm::Triple
> &Triple, const ArgList &Args)
> +@@ -228,8 +228,9 @@ Linux::Linux(const Driver &D, const llvm::Triple
> &Triple, const ArgList &Args)
>       : Generic_ELF(D, Triple, Args) {
>     GCCInstallation.TripleToDebianMultiarch = [](const llvm::Triple &T) {
>       StringRef TripleStr = T.str();
> diff --git
> a/meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch
> b/meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
> similarity index 89%
> rename from
> meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch
> rename to
> meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
> index 0b7966ee57..2beff16173 100644
> ---
> a/meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch
> +++
> b/meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
> @@ -1,4 +1,4 @@
> -From bf7c0933d65eb811c993ff32fdc6b65f6befc5af Mon Sep 17 00:00:00 2001
> +From 1ab2bd0edf76583f0e430da5ef8a53ca4029455f Mon Sep 17 00:00:00 2001
>  From: Maksim Kita <maksim-kita@yandex-team.ru>
>  Date: Sun, 23 May 2021 10:27:29 +0000
>  Subject: [PATCH] libunwind: Added unw_backtrace method
> @@ -12,7 +12,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   2 files changed, 21 insertions(+)
>
>  diff --git a/libunwind/include/libunwind.h b/libunwind/include/libunwind.h
> -index 56ca7110274a..60a27f28100b 100644
> +index 6c2dfe5..602cafb 100644
>  --- a/libunwind/include/libunwind.h
>  +++ b/libunwind/include/libunwind.h
>  @@ -235,6 +235,7 @@ extern int unw_is_signal_frame(unw_cursor_t *)
> LIBUNWIND_AVAIL;
> @@ -24,10 +24,10 @@ index 56ca7110274a..60a27f28100b 100644
>   extern unw_addr_space_t unw_local_addr_space;
>
>  diff --git a/libunwind/src/libunwind.cpp b/libunwind/src/libunwind.cpp
> -index 7ffffc2a30c0..ed0b394cb002 100644
> +index 0b9d56e..fbfbd48 100644
>  --- a/libunwind/src/libunwind.cpp
>  +++ b/libunwind/src/libunwind.cpp
> -@@ -531,6 +531,26 @@ int __unw_remove_find_dynamic_unwind_sections(
> +@@ -527,6 +527,26 @@ int __unw_remove_find_dynamic_unwind_sections(
>
>   #endif // __APPLE__
>
> diff --git
> a/meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch
> b/meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
> similarity index 92%
> rename from
> meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch
> rename to
> meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
> index b9f7270f62..45a71fc2ab 100644
> ---
> a/meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch
> +++
> b/meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
> @@ -1,4 +1,4 @@
> -From 94c6e940ddc44922ee505993549477a0fa7ac50d Mon Sep 17 00:00:00 2001
> +From 765a550228a57f9bf88ea2c284a5aec01c4c220e Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Tue, 8 Feb 2022 01:31:26 -0800
>  Subject: [PATCH] lldb: Link with libatomic on x86
> @@ -17,7 +17,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 4 insertions(+)
>
>  diff --git a/lldb/source/Utility/CMakeLists.txt
> b/lldb/source/Utility/CMakeLists.txt
> -index 04f1692e53b3..da0a48d9da54 100644
> +index c0d0a42..463c0d7 100644
>  --- a/lldb/source/Utility/CMakeLists.txt
>  +++ b/lldb/source/Utility/CMakeLists.txt
>  @@ -19,6 +19,10 @@ if (CMAKE_SYSTEM_NAME MATCHES "Windows")
> diff --git
> a/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
> b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
> deleted file mode 100644
> index 3fa436d526..0000000000
> ---
> a/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
> +++ /dev/null
> @@ -1,68 +0,0 @@
> -From bc8371eb77cca413ccb4ebf8239c597f7be40006 Mon Sep 17 00:00:00 2001
> -From: Khem Raj <raj.khem@gmail.com>
> -Date: Wed, 19 May 2021 17:32:13 -0700
> -Subject: [PATCH] compiler-rt: Do not use backtrace APIs on non-glibc linux
> -
> -musl e.g. does not provide backtrace APIs
> -
> -Upstream-Status: Pending
> -Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ----
> - .../lib/gwp_asan/optional/backtrace_linux_libc.cpp  | 13 ++++++++++++-
> - 1 file changed, 12 insertions(+), 1 deletion(-)
> -
> -diff --git a/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
> b/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
> -index ea8e72be287d..0344074dd254 100644
> ---- a/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
> -+++ b/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
> -@@ -7,7 +7,9 @@
> -
> //===----------------------------------------------------------------------===//
> -
> - #include <assert.h>
> -+#ifdef __GLIBC__
> - #include <execinfo.h>
> -+#endif
> - #include <stddef.h>
> - #include <stdint.h>
> - #include <stdlib.h>
> -@@ -21,8 +23,11 @@
> - namespace {
> - size_t Backtrace(uintptr_t *TraceBuffer, size_t Size) {
> -   static_assert(sizeof(uintptr_t) == sizeof(void *), "uintptr_t is not
> void*");
> --
> -+#ifdef __GLIBC__
> -   return backtrace(reinterpret_cast<void **>(TraceBuffer), Size);
> -+#else
> -+  return -1;
> -+#endif
> - }
> -
> - // We don't need any custom handling for the Segv backtrace - the libc
> unwinder
> -@@ -30,7 +35,11 @@ size_t Backtrace(uintptr_t *TraceBuffer, size_t Size) {
> - // to avoid the additional frame.
> - GWP_ASAN_ALWAYS_INLINE size_t SegvBacktrace(uintptr_t *TraceBuffer,
> size_t Size,
> -                                             void * /*Context*/) {
> -+#ifdef __GLIBC__
> -   return Backtrace(TraceBuffer, Size);
> -+#else
> -+  return -1;
> -+#endif
> - }
> -
> - static void PrintBacktrace(uintptr_t *Trace, size_t TraceLength,
> -@@ -40,6 +49,7 @@ static void PrintBacktrace(uintptr_t *Trace, size_t
> TraceLength,
> -     return;
> -   }
> -
> -+#ifdef __GLIBC__
> -   char **BacktraceSymbols =
> -       backtrace_symbols(reinterpret_cast<void **>(Trace), TraceLength);
> -
> -@@ -53,6 +63,7 @@ static void PrintBacktrace(uintptr_t *Trace, size_t
> TraceLength,
> -   Printf("\n");
> -   if (BacktraceSymbols)
> -     free(BacktraceSymbols);
> -+#endif
> - }
> - } // anonymous namespace
> -
> diff --git
> a/meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch
> b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
> similarity index 77%
> rename from
> meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch
> rename to
> meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
> index 89b492b877..12749e8f96 100644
> ---
> a/meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch
> +++
> b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
> @@ -1,4 +1,4 @@
> -From 968515d7aa2d7e4af5f318618c307dbe21538650 Mon Sep 17 00:00:00 2001
> +From 3a7b96edc836c0264206f01f5fc7e0cd1bc6c70c Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Wed, 9 Mar 2022 16:28:16 -0800
>  Subject: [PATCH] compiler-rt: Enable __int128 for ppc32
> @@ -6,15 +6,15 @@ Subject: [PATCH] compiler-rt: Enable __int128 for ppc32
>  Upstream-Status: Pending
>  Signed-off-by: Khem Raj <raj.khem@gmail.com>
>  ---
> - compiler-rt/lib/builtins/CMakeLists.txt | 13 ++++++-------
> + compiler-rt/lib/builtins/CMakeLists.txt | 17 ++++++-----------
>   compiler-rt/lib/builtins/int_types.h    |  2 +-
> - 2 files changed, 7 insertions(+), 8 deletions(-)
> + 2 files changed, 7 insertions(+), 12 deletions(-)
>
>  diff --git a/compiler-rt/lib/builtins/CMakeLists.txt
> b/compiler-rt/lib/builtins/CMakeLists.txt
> -index c3dbd65998f1..b3a44ea3c3b3 100644
> +index e128fea..eb108d7 100644
>  --- a/compiler-rt/lib/builtins/CMakeLists.txt
>  +++ b/compiler-rt/lib/builtins/CMakeLists.txt
> -@@ -813,11 +813,9 @@ set(mips64el_SOURCES ${GENERIC_TF_SOURCES}
> +@@ -916,11 +916,9 @@ set(mips64el_SOURCES ${GENERIC_TF_SOURCES}
>
>   set(nvptx64_SOURCES ${GENERIC_SOURCES})
>
> @@ -27,7 +27,7 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
>     ppc/divtc3.c
>     ppc/fixtfdi.c
>     ppc/fixunstfdi.c
> -@@ -832,14 +830,15 @@ set(powerpc64_SOURCES
> +@@ -935,11 +933,11 @@ set(powerpc64_SOURCES
>   )
>   # These routines require __int128, which isn't supported on AIX.
>   if (NOT OS_NAME MATCHES "AIX")
> @@ -40,13 +40,23 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
>  +    ${powerpc_SOURCES}
>     )
>   endif()
> + if (OS_NAME MATCHES "AIX")
> +@@ -947,12 +945,9 @@ if (OS_NAME MATCHES "AIX")
> +     ppc/init_ifuncs.c
> +     ${powerpc_SOURCES}
> +   )
> +-  set(powerpc64_SOURCES
> +-    ppc/init_ifuncs.c
> +-    ${powerpc64_SOURCES}
> +-  )
> + endif()
>  -set(powerpc64le_SOURCES ${powerpc64_SOURCES})
>  +set(powerpc64le_SOURCES ${powerpc_SOURCES})
>  +set(powerpc64_SOURCES ${powerpc_SOURCES})
>
>   set(riscv_SOURCES
>     cpu_model/riscv.c
> -@@ -1014,7 +1013,7 @@ else ()
> +@@ -1125,7 +1120,7 @@ else ()
>
>         # For RISCV32 and 32-bit SPARC, we must force enable int128 for
> compiling long
>         # double routines.
> @@ -56,7 +66,7 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
>           list(APPEND BUILTIN_CFLAGS_${arch} -fforce-enable-int128)
>         endif()
>  diff --git a/compiler-rt/lib/builtins/int_types.h
> b/compiler-rt/lib/builtins/int_types.h
> -index 7c7f8cb64aa9..81386f1b99b0 100644
> +index 6411507..754f8ce 100644
>  --- a/compiler-rt/lib/builtins/int_types.h
>  +++ b/compiler-rt/lib/builtins/int_types.h
>  @@ -64,7 +64,7 @@ typedef union {
> diff --git
> a/meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> b/meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> similarity index 91%
> rename from
> meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> rename to
> meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> index cccb1e9885..167cd12431 100644
> ---
> a/meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> +++
> b/meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> @@ -1,4 +1,4 @@
> -From 8c5fc285de0051107aa9b7e2e269aa2667fd16f4 Mon Sep 17 00:00:00 2001
> +From f610b9f158e13a40f0e86f7a171be493f8ca64fe Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Fri, 12 Aug 2022 11:50:57 -0700
>  Subject: [PATCH] llvm: Do not use cmake infra to detect libzstd
> @@ -21,7 +21,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 4 insertions(+), 4 deletions(-)
>
>  diff --git a/llvm/lib/Support/CMakeLists.txt
> b/llvm/lib/Support/CMakeLists.txt
> -index 099b0e55579b..8c35b8a31457 100644
> +index 1a3fa39..dd11f9a 100644
>  --- a/llvm/lib/Support/CMakeLists.txt
>  +++ b/llvm/lib/Support/CMakeLists.txt
>  @@ -22,7 +22,7 @@ if (HAS_WERROR_GLOBAL_CTORS)
> @@ -42,7 +42,7 @@ index 099b0e55579b..8c35b8a31457 100644
>   endif()
>
>   if( WIN32 )
> -@@ -351,7 +351,7 @@ if(LLVM_ENABLE_ZLIB)
> +@@ -360,7 +360,7 @@ if(LLVM_ENABLE_ZLIB)
>       get_property(zlib_library TARGET ZLIB::ZLIB PROPERTY LOCATION)
>     endif()
>     get_library_name(${zlib_library} zlib_library)
> @@ -51,7 +51,7 @@ index 099b0e55579b..8c35b8a31457 100644
>   endif()
>
>   if(LLVM_ENABLE_ZSTD)
> -@@ -365,7 +365,7 @@ if(LLVM_ENABLE_ZSTD)
> +@@ -374,7 +374,7 @@ if(LLVM_ENABLE_ZSTD)
>     endif()
>     if (zstd_target STREQUAL zstd::libzstd_shared)
>       get_library_name(${zstd_library} zstd_library)
> diff --git
> a/meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> b/meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> similarity index 91%
> rename from
> meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> rename to
> meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> index a498c36b84..021f622894 100644
> ---
> a/meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> +++
> b/meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> @@ -1,4 +1,4 @@
> -From 4a114f5fcd2ab8870b26ba3df4747fc066933f66 Mon Sep 17 00:00:00 2001
> +From 6917a5e0eb77c0134b59c3cb942292bc5c38e87f Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Tue, 3 Jan 2023 18:44:34 -0800
>  Subject: [PATCH] compiler-rt: Fix stat struct's size for O32 ABI
> @@ -14,7 +14,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 13 insertions(+)
>
>  diff --git
> a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
> b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
> -index 05ebee49f2ab..89c4dcaf3e3d 100644
> +index 73eb958..b0dcbde 100644
>  --- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
>  +++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
>  @@ -100,6 +100,18 @@ const unsigned struct_kernel_stat64_sz = 104;
> @@ -36,7 +36,7 @@ index 05ebee49f2ab..89c4dcaf3e3d 100644
>   const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
>                                              ? FIRST_32_SECOND_64(104, 128)
>   #      if defined(_ABIN32) && _MIPS_SIM == _ABIN32
> -@@ -110,6 +122,7 @@ const unsigned struct_kernel_stat_sz =
> SANITIZER_ANDROID
> +@@ -116,6 +128,7 @@ const unsigned struct_kernel_stat_sz =
> SANITIZER_ANDROID
>                                              : FIRST_32_SECOND_64(160,
> 216);
>   #      endif
>   const unsigned struct_kernel_stat64_sz = 104;
> diff --git
> a/meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> b/meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> similarity index 98%
> rename from
> meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> rename to
> meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> index 09224af386..19784aef10 100644
> ---
> a/meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> +++
> b/meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> @@ -1,4 +1,4 @@
> -From 27e4b9755ddd3bec16a851cce0df48e909ae6438 Mon Sep 17 00:00:00 2001
> +From 0d7e696f552b1047e89c5114551b6dc902e6f0f1 Mon Sep 17 00:00:00 2001
>  From: Martin Jansa <Martin.Jansa@gmail.com>
>  Date: Thu, 31 Aug 2023 18:14:47 +0200
>  Subject: [PATCH] ToolChains/Gnu.cpp: ARMLibDirs search also in lib32
> @@ -55,10 +55,10 @@ Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
>   2 files changed, 2 insertions(+), 1 deletion(-)
>
>  diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp
> b/clang/lib/Driver/ToolChains/Gnu.cpp
> -index 80fd8058bd98..37cb6cfdf2da 100644
> +index 73ff1f4..6a2b362 100644
>  --- a/clang/lib/Driver/ToolChains/Gnu.cpp
>  +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
> -@@ -2346,7 +2346,7 @@ void
> Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
> +@@ -2347,7 +2347,7 @@ void
> Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
>     static const char *const AArch64beLibDirs[] = {"/lib"};
>     static const char *const AArch64beTriples[] =
> {"aarch64_be-none-linux-gnu"};
>
> @@ -68,10 +68,10 @@ index 80fd8058bd98..37cb6cfdf2da 100644
>     static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
>
>  "armv7hl-redhat-linux-gnueabi",
>  diff --git a/clang/lib/Driver/ToolChains/Linux.cpp
> b/clang/lib/Driver/ToolChains/Linux.cpp
> -index 9fed904c05c2..5bb66c9faa1f 100644
> +index 41e0017..5f8b7fd 100644
>  --- a/clang/lib/Driver/ToolChains/Linux.cpp
>  +++ b/clang/lib/Driver/ToolChains/Linux.cpp
> -@@ -198,6 +198,7 @@ static StringRef getOSLibDir(const llvm::Triple
> &Triple, const ArgList &Args) {
> +@@ -199,6 +199,7 @@ static StringRef getOSLibDir(const llvm::Triple
> &Triple, const ArgList &Args) {
>     // reasoning about oslibdir spellings with the lib dir spellings in the
>     // GCCInstallationDetector, but that is a more significant refactoring.
>     if (Triple.getArch() == llvm::Triple::x86 || Triple.isPPC32() ||
> diff --git
> a/meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> b/meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> similarity index 60%
> rename from
> meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> rename to
> meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> index c93a9ec7e0..6577380978 100644
> ---
> a/meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> +++
> b/meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> @@ -1,4 +1,4 @@
> -From 7023d17f81a472e72a5739e007b9e7148d105137 Mon Sep 17 00:00:00 2001
> +From 33988376d79f9eca5f54000cdcc558c8dc3d89ba Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Sat, 3 Feb 2024 16:47:10 -0800
>  Subject: [PATCH] clang/llvm: Add OE specific ABI triple for N32 ABI
> @@ -8,16 +8,17 @@ Its gnun32 when using OE
>  Upstream-Status: Inappropriate [OE-Specific]
>  Signed-off-by: Khem Raj <raj.khem@gmail.com>
>  ---
> - clang/lib/Driver/ToolChains/Gnu.cpp   | 1 +
> - clang/lib/Driver/ToolChains/Linux.cpp | 4 ++--
> - llvm/lib/TargetParser/Triple.cpp      | 4 +++-
> - 3 files changed, 6 insertions(+), 3 deletions(-)
> + clang/lib/Driver/ToolChains/Gnu.cpp           | 1 +
> + clang/lib/Driver/ToolChains/Linux.cpp         | 4 ++--
> + llvm/include/llvm/TargetParser/TripleName.def | 2 +-
> + llvm/lib/TargetParser/Triple.cpp              | 2 ++
> + 4 files changed, 6 insertions(+), 3 deletions(-)
>
>  diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp
> b/clang/lib/Driver/ToolChains/Gnu.cpp
> -index 37cb6cfdf2da..bcd7d345c25a 100644
> +index 6a2b362..05d1c44 100644
>  --- a/clang/lib/Driver/ToolChains/Gnu.cpp
>  +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
> -@@ -2415,6 +2415,7 @@ void
> Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
> +@@ -2416,6 +2416,7 @@ void
> Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
>
>     static const char *const MIPSN32LibDirs[] = {"/lib32"};
>     static const char *const MIPSN32Triples[] = {"mips64-linux-gnuabin32",
> @@ -26,10 +27,10 @@ index 37cb6cfdf2da..bcd7d345c25a 100644
>     static const char *const MIPSN32ELLibDirs[] = {"/lib32"};
>     static const char *const MIPSN32ELTriples[] = {
>  diff --git a/clang/lib/Driver/ToolChains/Linux.cpp
> b/clang/lib/Driver/ToolChains/Linux.cpp
> -index 5bb66c9faa1f..c6d6e20dbc4d 100644
> +index 5f8b7fd..ac7bd3a 100644
>  --- a/clang/lib/Driver/ToolChains/Linux.cpp
>  +++ b/clang/lib/Driver/ToolChains/Linux.cpp
> -@@ -138,7 +138,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
> +@@ -139,7 +139,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
>       return IsMipsR6 ? "mipsisa32r6el-linux-gnu" : "mipsel-linux-gnu";
>     case llvm::Triple::mips64: {
>       std::string MT = std::string(IsMipsR6 ? "mipsisa64r6" : "mips64") +
> @@ -38,7 +39,7 @@ index 5bb66c9faa1f..c6d6e20dbc4d 100644
>       if (D.getVFS().exists(concat(SysRoot, "/lib", MT)))
>         return MT;
>       if (D.getVFS().exists(concat(SysRoot, "/lib/mips64-linux-gnu")))
> -@@ -147,7 +147,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
> +@@ -148,7 +148,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
>     }
>     case llvm::Triple::mips64el: {
>       std::string MT = std::string(IsMipsR6 ? "mipsisa64r6el" :
> "mips64el") +
> @@ -47,28 +48,32 @@ index 5bb66c9faa1f..c6d6e20dbc4d 100644
>       if (D.getVFS().exists(concat(SysRoot, "/lib", MT)))
>         return MT;
>       if (D.getVFS().exists(concat(SysRoot, "/lib/mips64el-linux-gnu")))
> +diff --git a/llvm/include/llvm/TargetParser/TripleName.def
> b/llvm/include/llvm/TargetParser/TripleName.def
> +index bbc03b3..081d8ff 100644
> +--- a/llvm/include/llvm/TargetParser/TripleName.def
> ++++ b/llvm/include/llvm/TargetParser/TripleName.def
> +@@ -102,7 +102,7 @@ TRIPLE_OS(H2, "h2")
> +
> + TRIPLE_ENV(EABIHF, "eabihf")
> + TRIPLE_ENV(EABI, "eabi")
> +-TRIPLE_ENV(GNUABIN32, "gnuabin32")
> ++TRIPLE_ENV(GNUABIN32, "gnun32")
> + TRIPLE_ENV(GNUABI64, "gnuabi64")
> + TRIPLE_ENV(GNUEABIHFT64, "gnueabihft64")
> + TRIPLE_ENV(GNUEABIHF, "gnueabihf")
>  diff --git a/llvm/lib/TargetParser/Triple.cpp
> b/llvm/lib/TargetParser/Triple.cpp
> -index 86b74451ec0d..d94b7d44d11a 100644
> +index 883e654..aa2bb35 100644
>  --- a/llvm/lib/TargetParser/Triple.cpp
>  +++ b/llvm/lib/TargetParser/Triple.cpp
> -@@ -358,7 +358,7 @@ StringRef
> Triple::getEnvironmentTypeName(EnvironmentType Kind) {
> -   case GNU: return "gnu";
> -   case GNUT64: return "gnut64";
> -   case GNUABI64: return "gnuabi64";
> --  case GNUABIN32: return "gnuabin32";
> -+  case GNUABIN32: return "gnun32";
> -   case GNUEABI: return "gnueabi";
> -   case GNUEABIT64: return "gnueabit64";
> -   case GNUEABIHF: return "gnueabihf";
> -@@ -762,6 +762,7 @@ static Triple::EnvironmentType
> parseEnvironment(StringRef EnvironmentName) {
> -       .StartsWith("eabihf", Triple::EABIHF)
> -       .StartsWith("eabi", Triple::EABI)
> -       .StartsWith("gnuabin32", Triple::GNUABIN32)
> -+      .StartsWith("gnun32", Triple::GNUABIN32)
> -       .StartsWith("gnuabi64", Triple::GNUABI64)
> -       .StartsWith("gnueabihft64", Triple::GNUEABIHFT64)
> -       .StartsWith("gnueabihf", Triple::GNUEABIHF)
> -@@ -1087,6 +1088,7 @@ Triple::Triple(std::string &&Str) :
> Data(std::move(Str)) {
> +@@ -755,6 +755,7 @@ static Triple::OSType parseOS(StringRef OSName) {
> +
> + static Triple::EnvironmentType parseEnvironment(StringRef
> EnvironmentName) {
> +   return StringSwitch<Triple::EnvironmentType>(EnvironmentName)
> ++      .StartsWith("gnuabin32", Triple::GNUABIN32)
> + #define TRIPLE_ENV(Enum, Name) .StartsWith(Name, Triple::Enum)
> + #include "llvm/TargetParser/TripleName.def"
> +       .Default(Triple::UnknownEnvironment);
> +@@ -1106,6 +1107,7 @@ Triple::Triple(std::string &&Str) :
> Data(std::move(Str)) {
>         Environment =
>             StringSwitch<Triple::EnvironmentType>(Components[0])
>                 .StartsWith("mipsn32", Triple::GNUABIN32)
>

   .def already has an alias mechanism (TRIPLE_VENDOR_ALIAS appears in the
vendor rework) — if TRIPLE_ENV_ALIAS exists too, using it for gnuabin32
would keep the compat spelling in the table itself instead of hand-editing
parseEnvironment, which will rebase more cleanly next


> diff --git
> a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> b/meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> similarity index 84%
> rename from
> meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> rename to
> meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> index 72ffdc6c1f..34ba534074 100644
> ---
> a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> +++
> b/meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> @@ -1,4 +1,4 @@
> -From 17a1a4919c0ff554fc30bbb85a63b9d2a1164324 Mon Sep 17 00:00:00 2001
> +From 9ec97845821ead65ebd8ab26b69d949e10b65338 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Tue, 14 May 2024 22:04:43 -0700
>  Subject: [PATCH] llvm: Add libunwind.pc.in and llvm-config scripts
> @@ -10,15 +10,15 @@ Upstream-Status: Inappropriate [ OE-Specific ]
>  Signed-off-by: Khem Raj <raj.khem@gmail.com>
>  Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>  ---
> - libunwind/libunwind.pc.in          |  9 ++++++
> - llvm/tools/llvm-config/llvm-config | 52 ++++++++++++++++++++++++++++++
> - 2 files changed, 61 insertions(+)
> + libunwind/libunwind.pc.in          |  9 +++++++++
> + llvm/tools/llvm-config/llvm-config | 15 +++++++++++++++
> + 2 files changed, 24 insertions(+)
>   create mode 100644 libunwind/libunwind.pc.in
>   create mode 100644 llvm/tools/llvm-config/llvm-config
>
>  diff --git a/libunwind/libunwind.pc.in b/libunwind/libunwind.pc.in
>  new file mode 100644
> -index 000000000000..a93d676604f9
> +index 0000000..a93d676
>  --- /dev/null
>  +++ b/libunwind/libunwind.pc.in
>  @@ -0,0 +1,9 @@
> @@ -33,7 +33,7 @@ index 000000000000..a93d676604f9
>  +Libs: -lunwind
>  diff --git a/llvm/tools/llvm-config/llvm-config
> b/llvm/tools/llvm-config/llvm-config
>  new file mode 100644
> -index 000000000000..6a0dd54b8eab
> +index 0000000..0578773
>  --- /dev/null
>  +++ b/llvm/tools/llvm-config/llvm-config
>  @@ -0,0 +1,15 @@
> diff --git
> a/meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> b/meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> similarity index 90%
> rename from
> meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> rename to
> meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> index 934d5adc50..55ad603b7c 100644
> ---
> a/meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> +++
> b/meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> @@ -1,7 +1,8 @@
> -From a2171be64a181e0b263fc8ec31a760193651203c Mon Sep 17 00:00:00 2001
> +From b9565c7e6525f3ca20df3171c36698b521a45594 Mon Sep 17 00:00:00 2001
>  From: Martin Jansa <martin.jansa@gmail.com>
>  Date: Fri, 13 Sep 2024 13:38:08 +0200
> -Subject: [PATCH] scan-build-py: respect LLVM_LIBDIR_SUFFIX like other
> tools do
> +Subject: [PATCH] scan-build-py: respect LLVM_LIBDIR_SUFFIX like other
> + tools do
>
>  * other libraries are installed in 'lib64' or 'lib32' based on
>    LLVM_LIBDIR_SUFFIX value, but libscanbuild files were always
> @@ -11,13 +12,13 @@ Upstream-Status: Submitted [
> https://github.com/llvm/llvm-project/pull/108549]
>
>  Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
>  ---
> - clang/tools/scan-build-py/CMakeLists.txt | 26 ++++++++++++------------
> - 1 file changed, 13 insertions(+), 13 deletions(-)
> + clang/tools/scan-build-py/CMakeLists.txt | 32 ++++++++++++------------
> + 1 file changed, 16 insertions(+), 16 deletions(-)
>
> -Index: llvm-project-22.1.2.src/clang/tools/scan-build-py/CMakeLists.txt
> -===================================================================
> ---- llvm-project-22.1.2.src.orig/clang/tools/scan-build-py/CMakeLists.txt
> -+++ llvm-project-22.1.2.src/clang/tools/scan-build-py/CMakeLists.txt
> +diff --git a/clang/tools/scan-build-py/CMakeLists.txt
> b/clang/tools/scan-build-py/CMakeLists.txt
> +index 84087a9..9647642 100644
> +--- a/clang/tools/scan-build-py/CMakeLists.txt
> ++++ b/clang/tools/scan-build-py/CMakeLists.txt
>  @@ -80,52 +80,52 @@ if(CLANG_INSTALL_SCANBUILDPY)
>     endforeach()
>
> diff --git
> a/meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> b/meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> similarity index 91%
> rename from
> meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> rename to
> meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> index fe24fe051b..b3fb642742 100644
> ---
> a/meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> +++
> b/meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> @@ -1,4 +1,4 @@
> -From 6b1f360c66b60c4bb639057590a8b2162d3bcf6b Mon Sep 17 00:00:00 2001
> +From f68925e7c31fa4bdd684a4ab44fd1350bb43205b Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Thu, 13 Mar 2025 00:30:38 -0700
>  Subject: [PATCH] compiler-rt: Do not pass --target to clang compiler
> @@ -13,7 +13,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 4 deletions(-)
>
>  diff --git a/compiler-rt/lib/fuzzer/CMakeLists.txt
> b/compiler-rt/lib/fuzzer/CMakeLists.txt
> -index a57e2fe46245..2928ed2ab6d5 100644
> +index 2da488d..9af4410 100644
>  --- a/compiler-rt/lib/fuzzer/CMakeLists.txt
>  +++ b/compiler-rt/lib/fuzzer/CMakeLists.txt
>  @@ -140,10 +140,6 @@ if(OS_NAME MATCHES "Android|Linux|Fuchsia" AND
> diff --git
> a/meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> b/meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> similarity index 92%
> rename from
> meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> rename to
> meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> index 413bc3f275..28d0567e15 100644
> ---
> a/meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> +++
> b/meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> @@ -1,4 +1,4 @@
> -From 281cd05306cbfa5744e4a1f3ebf5c745324efe7a Mon Sep 17 00:00:00 2001
> +From bf8a65efcdce65143081785b9ed8759d60be1bd4 Mon Sep 17 00:00:00 2001
>  From: Alexander Kanavin <alex.kanavin@gmail.com>
>  Date: Fri, 27 Nov 2020 10:11:08 +0000
>  Subject: [PATCH] AsmMatcherEmitter: sort ClassInfo lists by name as well
> @@ -14,7 +14,7 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com
> >
>   1 file changed, 4 insertions(+), 1 deletion(-)
>
>  diff --git a/llvm/utils/TableGen/AsmMatcherEmitter.cpp
> b/llvm/utils/TableGen/AsmMatcherEmitter.cpp
> -index e6085af5aa91..b0180638c754 100644
> +index 4af5c85..917aeec 100644
>  --- a/llvm/utils/TableGen/AsmMatcherEmitter.cpp
>  +++ b/llvm/utils/TableGen/AsmMatcherEmitter.cpp
>  @@ -384,7 +384,10 @@ public:
> diff --git
> a/meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> b/meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> similarity index 92%
> rename from
> meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> rename to
> meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> index e059748873..7724af8009 100644
> ---
> a/meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> +++
> b/meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> @@ -1,4 +1,4 @@
> -From cbc2595eed96fa7de77162e4c7b99681579d01ef Mon Sep 17 00:00:00 2001
> +From f58186cc6ba2fff4d2e9fb624a904b1c5a4f7733 Mon Sep 17 00:00:00 2001
>  From: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
>  Date: Wed, 2 Apr 2025 17:05:17 +0300
>  Subject: [PATCH] llvm-config: remove LLVM_LDFLAGS from --ldflags output
> @@ -18,7 +18,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
>  diff --git a/llvm/tools/llvm-config/llvm-config.cpp
> b/llvm/tools/llvm-config/llvm-config.cpp
> -index 0a3f51ae2b83..5c95a1f3ff24 100644
> +index 64795e9..3e57005 100644
>  --- a/llvm/tools/llvm-config/llvm-config.cpp
>  +++ b/llvm/tools/llvm-config/llvm-config.cpp
>  @@ -576,7 +576,7 @@ int main(int argc, char **argv) {
> diff --git
> a/meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> b/meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> similarity index 95%
> rename from
> meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> rename to
> meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> index 52bdeaf9d5..a1847f99f9 100644
> ---
> a/meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> +++
> b/meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> @@ -1,4 +1,4 @@
> -From 3a486a17b697c65cdc7d2c17d9e14f2bfc2be911 Mon Sep 17 00:00:00 2001
> +From 9046478db7833765487e66d5a3706b7cb67f1ee2 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Sat, 10 May 2025 14:03:12 -0700
>  Subject: [PATCH] compiler-rt: Exclude sync_fetch_and_* for any pre-ARMv6
> @@ -40,10 +40,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 12 insertions(+)
>
>  diff --git a/compiler-rt/lib/builtins/CMakeLists.txt
> b/compiler-rt/lib/builtins/CMakeLists.txt
> -index b3a44ea3c3b3..4a328ab0ca26 100644
> +index eb108d7..4041119 100644
>  --- a/compiler-rt/lib/builtins/CMakeLists.txt
>  +++ b/compiler-rt/lib/builtins/CMakeLists.txt
> -@@ -975,6 +975,18 @@ else ()
> +@@ -1082,6 +1082,18 @@ else ()
>           ${TARGET_${arch}_CFLAGS})
>         list(JOIN CMAKE_REQUIRED_FLAGS " " CMAKE_REQUIRED_FLAGS)
>         message(STATUS "Performing additional configure checks with target
> flags: ${CMAKE_REQUIRED_FLAGS}")
> diff --git
> a/meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
> b/meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
> similarity index 86%
> rename from
> meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
> rename to
> meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
> index b0aae5457a..d3a9a6c308 100644
> ---
> a/meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
> +++
> b/meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
> @@ -1,7 +1,7 @@
> -From b71c398a1b10b29886c2db2a920f476fec6f7de2 Mon Sep 17 00:00:00 2001
> +From aab77dfb9c2e1a118ffb5bd690f34bf93b6f3f36 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Thu, 22 May 2025 21:50:45 -0700
> -Subject: [PATCH] [compiler-rt] Hardcode uptr/sptr typedefs on Mips/Linux
> +Subject: [PATCH] Hardcode uptr/sptr typedefs on Mips/Linux
>
>  Sanitizer build on Mips/Linux faills to build due to assertion errors
>  mismatched definitions. This is due to inconsistent definitions of
> @@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
>  diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
> b/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
> -index c719e2a8ef60..60b997e653c4 100644
> +index c694897..08f6d35 100644
>  --- a/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
>  +++ b/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
> -@@ -139,7 +139,7 @@
> +@@ -143,7 +143,7 @@
>   namespace __sanitizer {
>
>   #if defined(__UINTPTR_TYPE__)
> diff --git
> a/meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> b/meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> similarity index 89%
> rename from
> meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> rename to
> meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> index 57003dcf56..faae71645a 100644
> ---
> a/meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> +++
> b/meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> @@ -1,4 +1,4 @@
> -From 9ace97c0c2df52d823c9d5345cca0251bf2ccf16 Mon Sep 17 00:00:00 2001
> +From cffcea54bf4605d958407edb233fffdbe730f4af Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Sun, 27 Jul 2025 19:12:13 -0700
>  Subject: [PATCH] Revert "[libc++] Remap headers in the debug info when
> @@ -19,10 +19,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 5 deletions(-)
>
>  diff --git a/libcxx/include/CMakeLists.txt b/libcxx/include/CMakeLists.txt
> -index 787cfffa5019..d73bcd852a1e 100644
> +index b40f586..7bd7622 100644
>  --- a/libcxx/include/CMakeLists.txt
>  +++ b/libcxx/include/CMakeLists.txt
> -@@ -1718,11 +1718,6 @@ add_dependencies(cxx-headers generate-cxx-headers)
> +@@ -1728,11 +1728,6 @@ add_dependencies(cxx-headers generate-cxx-headers)
>   target_include_directories(cxx-headers INTERFACE
> ${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}
>
>  ${LIBCXX_GENERATED_INCLUDE_DIR})
>
> diff --git
> a/meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> b/meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> similarity index 86%
> rename from
> meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> rename to
> meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> index 0cdb2ad668..af9564053c 100644
> ---
> a/meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> +++
> b/meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> @@ -1,4 +1,4 @@
> -From 53da129f7986c5bd310f4f4a8236987df7e073c6 Mon Sep 17 00:00:00 2001
> +From b6a9ddd0ba2d8bd14871c135157f3878a9d629c1 Mon Sep 17 00:00:00 2001
>  From: Ross Burton <ross.burton@arm.com>
>  Date: Mon, 29 Sep 2025 14:44:05 +0100
>  Subject: [PATCH] Don't expose LLVM_HAVE_OPT_VIEWER_MODULES externally
> @@ -14,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 1 deletion(-)
>
>  diff --git a/llvm/cmake/modules/LLVMConfig.cmake.in b/llvm/cmake/modules/
> LLVMConfig.cmake.in
> -index 70c807abea98..5603c9215332 100644
> +index 6f5fcc6..ce07563 100644
>  --- a/llvm/cmake/modules/LLVMConfig.cmake.in
>  +++ b/llvm/cmake/modules/LLVMConfig.cmake.in
> -@@ -137,7 +137,6 @@ set(LLVM_DEFINITIONS "@LLVM_DEFINITIONS@")
> +@@ -145,7 +145,6 @@ set(LLVM_DEFINITIONS "@LLVM_DEFINITIONS@")
>   set(LLVM_BINARY_DIR "@LLVM_CONFIG_BINARY_DIR@")
>   set(LLVM_CMAKE_DIR "@LLVM_CONFIG_CMAKE_DIR@")
>   set(LLVM_TOOLS_BINARY_DIR "@LLVM_CONFIG_TOOLS_BINARY_DIR@")
> diff --git
> a/meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
> b/meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
> similarity index 81%
> rename from
> meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
> rename to
> meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
> index 5efe043eaf..690791c5e3 100644
> ---
> a/meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
> +++
> b/meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
> @@ -1,7 +1,7 @@
> -From de58b9bbc8c52299ff22c4f0ab21e3878d411669 Mon Sep 17 00:00:00 2001
> +From a55e7674203ffcb42e4e3ee4c8cf7aa964aee086 Mon Sep 17 00:00:00 2001
>  From: Ross Burton <ross.burton@arm.com>
>  Date: Sat, 11 Oct 2025 16:01:50 -0700
> -Subject: [PATCH] [clang] Only build clang-tblgen if it is actually needed
> +Subject: [PATCH] Only build clang-tblgen if it is actually needed
>
>  It's possible to build clang with an existing clang-tblgen (common when
>  cross-compiling, for instance) by setting CLANG_TABLEGEN_EXE.  If this
> @@ -16,10 +16,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 3 insertions(+), 1 deletion(-)
>
>  diff --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt
> -index e4cb1a359620..b650b3b986f4 100644
> +index 89f584c..bd7ebc3 100644
>  --- a/clang/CMakeLists.txt
>  +++ b/clang/CMakeLists.txt
> -@@ -479,7 +479,9 @@ option(CLANG_ENABLE_HLSL "Include HLSL build
> products" Off)
> +@@ -531,7 +531,9 @@ option(CLANG_ENABLE_HLSL "Include HLSL build
> products" Off)
>   # While HLSL support is experimental this should stay hidden.
>   mark_as_advanced(CLANG_ENABLE_HLSL)
>
> diff --git
> a/meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> b/meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> similarity index 93%
> rename from
> meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> rename to
> meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> index 583e91e497..6081f2d7b4 100644
> ---
> a/meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> +++
> b/meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> @@ -1,4 +1,4 @@
> -From bca77d818187e68989dfa9e386b38632b76a477e Mon Sep 17 00:00:00 2001
> +From b383508d002bb41ac979ab356f73fcf0ae97ca00 Mon Sep 17 00:00:00 2001
>  From: Khem Raj <raj.khem@gmail.com>
>  Date: Tue, 28 Oct 2025 15:44:49 -0700
>  Subject: [PATCH] llvm-libgcc: Fix symlink path for libcc when
> @@ -33,10 +33,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
>   1 file changed, 13 insertions(+), 3 deletions(-)
>
>  diff --git a/llvm-libgcc/CMakeLists.txt b/llvm-libgcc/CMakeLists.txt
> -index 47208fc19869..54009c1104c3 100644
> +index a297447..1ae9167 100644
>  --- a/llvm-libgcc/CMakeLists.txt
>  +++ b/llvm-libgcc/CMakeLists.txt
> -@@ -124,11 +124,21 @@ target_link_libraries(unwind_shared PUBLIC
> +@@ -133,11 +133,21 @@ target_link_libraries(unwind_shared PUBLIC
>
> #===============================================================================
>
>   get_compiler_rt_install_dir(${COMPILER_RT_DEFAULT_TARGET_ARCH}
> install_dir_builtins)
> @@ -60,7 +60,7 @@ index 47208fc19869..54009c1104c3 100644
>     string(PREPEND install_dir_builtins "../")
>   endif()
>   set(LLVM_LIBGCC_COMPILER_RT
> ${install_dir_builtins}/libclang_rt.builtins${builtins_suffix}.a)
> -@@ -137,7 +147,7 @@ add_custom_target(llvm-libgcc ALL
> +@@ -146,7 +156,7 @@ add_custom_target(llvm-libgcc ALL
>     DEPENDS unwind_shared unwind_static
> clang_rt.builtins-${COMPILER_RT_DEFAULT_TARGET_ARCH}
>     COMMAND ${CMAKE_COMMAND} -E create_symlink ${LLVM_LIBGCC_COMPILER_RT}
> libgcc.a
>     COMMAND ${CMAKE_COMMAND} -E create_symlink libunwind.a libgcc_eh.a
> diff --git
> a/meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> b/meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> similarity index 91%
> rename from
> meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> rename to
> meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> index a2a7fa80f1..ecaaa738a7 100644
> ---
> a/meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> +++
> b/meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> @@ -1,7 +1,8 @@
> -From b818a92ac171e80e39ad9e99d1f862d23f2bb5b3 Mon Sep 17 00:00:00 2001
> +From 7da49a0e48fa77d38548f8f1dedc7cb1bb8dce53 Mon Sep 17 00:00:00 2001
>  From: "mark.yang" <mark.yang@lge.com>
>  Date: Tue, 14 Apr 2026 16:17:01 +0900
> -Subject: [PATCH] Consolidate and fix sysroot-based compiler-rt search
> paths
> +Subject: [PATCH] Consolidate and fix sysroot-based compiler-rt search
> + paths
>
>  Consolidate patches 0008 and 0033 into a single patch with a fix for
>  native builds.
> @@ -41,10 +42,10 @@ Signed-off-by: mark.yang <mark.yang@lge.com>
>   1 file changed, 28 insertions(+), 3 deletions(-)
>
>  diff --git a/clang/lib/Driver/ToolChain.cpp
> b/clang/lib/Driver/ToolChain.cpp
> -index 77a2c73f0..ac28b51c4 100644
> +index f894a06..eceada5 100644
>  --- a/clang/lib/Driver/ToolChain.cpp
>  +++ b/clang/lib/Driver/ToolChain.cpp
> -@@ -15,6 +15,7 @@
> +@@ -16,6 +16,7 @@
>   #include "ToolChains/InterfaceStubs.h"
>   #include "clang/Basic/ObjCRuntime.h"
>   #include "clang/Basic/Sanitizers.h"
> @@ -52,7 +53,7 @@ index 77a2c73f0..ac28b51c4 100644
>   #include "clang/Config/config.h"
>   #include "clang/Driver/Action.h"
>   #include "clang/Driver/CommonArgs.h"
> -@@ -723,7 +724,15 @@ StringRef ToolChain::getOSLibName() const {
> +@@ -872,7 +873,15 @@ StringRef ToolChain::getOSLibName() const {
>   }
>
>   std::string ToolChain::getCompilerRTPath() const {
> @@ -69,7 +70,7 @@ index 77a2c73f0..ac28b51c4 100644
>     if (isBareMetal()) {
>       llvm::sys::path::append(Path, "lib", getOSLibName());
>       if (!SelectedMultilibs.empty()) {
> -@@ -1021,7 +1030,15 @@ ToolChain::getTargetSubDirPath(StringRef BaseDir)
> const {
> +@@ -1179,7 +1188,15 @@ std::optional<std::string>
> ToolChain::getDefaultIntrinsicModuleDir() const {
>   }
>
>   std::optional<std::string> ToolChain::getRuntimePath() const {
> @@ -86,7 +87,7 @@ index 77a2c73f0..ac28b51c4 100644
>     llvm::sys::path::append(P, "lib");
>     if (auto Ret = getTargetSubDirPath(P))
>       return Ret;
> -@@ -1049,7 +1066,15 @@ ToolChain::path_list
> ToolChain::getArchSpecificLibPaths() const {
> +@@ -1207,7 +1224,15 @@ ToolChain::path_list
> ToolChain::getArchSpecificLibPaths() const {
>     path_list Paths;
>
>     auto AddPath = [&](const ArrayRef<StringRef> &SS) {
> diff --git
> a/meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch
> b/meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
> similarity index 83%
> rename from
> meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch
> rename to
> meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
> index 9b4e29ff64..5e53d43944 100644
> ---
> a/meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch
> +++
> b/meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
> @@ -1,3 +1,8 @@
> +From 9463b5d24fc62372fc2731d4d4665c64c72b55b2 Mon Sep 17 00:00:00 2001
> +From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> +Date: Wed, 19 Aug 2026 22:46:10 +0530
> +Subject: [PATCH] guard clang-tools-extra test
> +
>  clang-tools-extra tests depend on the llvm-bcanalyzer CMake target, which
>  exists in LLVM's CMake project but is not visible when Clang is built
>  separately. To run clang tests, disable clang-tools-extra tests for now.
> @@ -22,30 +27,49 @@ Without this patch when CLANG_INCLUDE_TESTS is ON got
> the following error
>
>  -------------------------------------------------------------------------------
>
>  Upstream-Status: Inappropriate [OE-Specific]
> +
>  Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> +---
> + clang-tools-extra/CMakeLists.txt                 | 4 ++--
> + clang-tools-extra/clangd/CMakeLists.txt          | 2 +-
> + clang-tools-extra/include-cleaner/CMakeLists.txt | 2 +-
> + 3 files changed, 4 insertions(+), 4 deletions(-)
>
>  diff --git a/clang-tools-extra/CMakeLists.txt
> b/clang-tools-extra/CMakeLists.txt
> -index 6b6f2b1..26e4c10 100644
> +index 87050db..3824129 100644
>  --- a/clang-tools-extra/CMakeLists.txt
>  +++ b/clang-tools-extra/CMakeLists.txt
> -@@ -8,7 +8,7 @@ include(GNUInstallDirs)
> +@@ -8,7 +8,7 @@ option(CLANG_TIDY_ENABLE_STATIC_ANALYZER
>   option(CLANG_TIDY_ENABLE_QUERY_BASED_CUSTOM_CHECKS
>     "Enable query-based custom checks in clang-tidy" ON)
> -
> +
>  -if(CLANG_INCLUDE_TESTS)
>  +if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
>     umbrella_lit_testsuite_begin(check-clang-tools)
> -
> +
>     option(CLANG_TOOLS_TEST_USE_VG "Run Clang tools' tests under Valgrind"
> OFF)
>  @@ -45,7 +45,7 @@ if (CLANG_ENABLE_CLANGD)
>   endif()
> -
> +
>   # Add the common testsuite after all the tools.
>  -if(CLANG_INCLUDE_TESTS)
>  +if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
>     add_subdirectory(test)
>     add_subdirectory(unittests)
>     umbrella_lit_testsuite_end(check-clang-tools)
> +diff --git a/clang-tools-extra/clangd/CMakeLists.txt
> b/clang-tools-extra/clangd/CMakeLists.txt
> +index 890562d..c4d6623 100644
> +--- a/clang-tools-extra/clangd/CMakeLists.txt
> ++++ b/clang-tools-extra/clangd/CMakeLists.txt
> +@@ -217,7 +217,7 @@ endif()
> + option(CLANGD_BUILD_DEXP "Build the dexp tool as part of Clangd" ON)
> + llvm_canonicalize_cmake_booleans(CLANGD_BUILD_DEXP)
> +
> +-if(CLANG_INCLUDE_TESTS)
> ++if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
> +   add_subdirectory(test)
> +   add_subdirectory(unittests)
> + endif()
>  diff --git a/clang-tools-extra/include-cleaner/CMakeLists.txt
> b/clang-tools-extra/include-cleaner/CMakeLists.txt
>  index dc147f9..4855577 100644
>  --- a/clang-tools-extra/include-cleaner/CMakeLists.txt
> @@ -59,16 +83,3 @@ index dc147f9..4855577 100644
>     add_subdirectory(test)
>     add_subdirectory(unittests)
>   endif()
> -diff --git a/clang-tools-extra/clangd/CMakeLists.txt
> b/clang-tools-extra/clangd/CMakeLists.txt
> -index a1e9da4..94dcb96 100644
> ---- a/clang-tools-extra/clangd/CMakeLists.txt
> -+++ b/clang-tools-extra/clangd/CMakeLists.txt
> -@@ -215,7 +215,7 @@ endif()
> - option(CLANGD_BUILD_DEXP "Build the dexp tool as part of Clangd" ON)
> - llvm_canonicalize_cmake_booleans(CLANGD_BUILD_DEXP)
> -
> --if(CLANG_INCLUDE_TESTS)
> -+if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
> -   add_subdirectory(test)
> -   add_subdirectory(unittests)
> - endif()
> diff --git
> a/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
> b/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
> deleted file mode 100644
> index 6021f736ff..0000000000
> ---
> a/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
> +++ /dev/null
> @@ -1,41 +0,0 @@
> -From 051b3bfa1e0e5cfed4a02318e330b38b0090cc49 Mon Sep 17 00:00:00 2001
> -From: Serge Pavlov <sepavloff@gmail.com>
> -Date: Fri, 25 Jul 2025 13:35:19 +0700
> -Subject: [PATCH] Prevent revisiting block when searching for noreturn vars
> -
> -When searching for noreturn variable initializations, do not visit CFG
> -blocks that are already visited, it prevents hanging  the analysis.
> -
> -It must fix https://github.com/llvm/llvm-project/issues/150336.
> -
> -Upstream-Status: Submitted [
> https://github.com/llvm/llvm-project/pull/150582]
> -Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ----
> - clang/test/SemaCXX/noreturn-vars.cpp | 17 +++++++++++++++++
> - 1 file changed, 17 insertions(+)
> -
> -diff --git a/clang/test/SemaCXX/noreturn-vars.cpp
> b/clang/test/SemaCXX/noreturn-vars.cpp
> -index ca65fcf5ca31..1bf074149f04 100644
> ---- a/clang/test/SemaCXX/noreturn-vars.cpp
> -+++ b/clang/test/SemaCXX/noreturn-vars.cpp
> -@@ -225,3 +225,20 @@ extern void abc_02(func_type *);
> -   abc_02(&func_ptr);
> -   func_ptr();
> - } // expected-warning {{function declared 'noreturn' should not return}}
> -+
> -+namespace Issue150336 {
> -+void free(void *);
> -+typedef void (*sel_freefunc)(void *);
> -+struct gmx_ana_selmethod_t {
> -+  sel_freefunc free;
> -+  int nparams;
> -+  int *param;
> -+};
> -+void gmx_selelem_free_method(struct gmx_ana_selmethod_t* method, void*
> mdata) {
> -+    sel_freefunc free_func = 0;
> -+    for (int i = 0; i < method->nparams; ++i)
> -+        free(&method->param[i]);
> -+    if (mdata && free_func)
> -+        free_func(mdata);
> -+}
> -+}
> diff --git
> a/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
> b/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
> new file mode 100644
> index 0000000000..df35636055
> --- /dev/null
> +++
> b/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
> @@ -0,0 +1,36 @@
> +From: Sunil Dora <sunilkumar.dora@windriver.com>
> +Date: Fri, 29 Aug 2026 13:55:00 +0530
> +Subject: [PATCH] libc: Disable float16 on 32-bit x86 without SSE2
> +
> +GCC 16 defines __FLT16_MANT_DIG__ when targeting i686 even though
> +_Float16 is only usable on x86-32 with SSE2 enabled. The float16
> +detection in float16-macros.h keys on that macro, so the shared f16
> +math headers are compiled on plain i686 and every use of _Float16
> +fails:
> +
> +  libc/src/__support/FPUtil/BasicOperations.h:63:67:
> +      error: SSE register return with SSE2 disabled
> +  libc/src/__support/math/acosf16.h:73:14:
> +      error: invalid conversion from type '_Float16' without option
> '-msse2'
> +
> +Since llvm/lib/Support/APFloat.cpp started including shared/math.h,
> +this breaks the LLVM build itself for 32-bit x86 baselines older than
> +SSE2 (e.g. -march=pentiumpro), as used by Yocto/OpenEmbedded multilib.
> +
> +Require SSE2 on 32-bit x86 in the guard, matching the existing
> +exclusions for 32-bit Arm and RISC-V. Targets with SSE2 are unaffected.
> +
> +Upstream-Status: Backport [
> https://github.com/llvm/llvm-project/commit/05da143c63d333420b99eab198e1a89c97480929
> ]
> +Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
> +---
> +--- a/libc/include/llvm-libc-macros/float16-macros.h   2026-08-29
> 13:55:04.771442947 +0530
> ++++ b/libc/include/llvm-libc-macros/float16-macros.h   2026-08-29
> 13:55:04.773991812 +0530
> +@@ -15,7 +15,7 @@
> +     (!defined(__GNUC__) || __GNUC__ >= 13 ||
>        \
> +      (defined(__clang__) && __clang_major__ >= 12)) &&
>        \
> +     !defined(__arm__) && !defined(_M_ARM) && !defined(__riscv) &&
>       \
> +-    !defined(_WIN32)
> ++    !defined(_WIN32) && (!defined(__i386__) || defined(__SSE2__))
> + #define LIBC_TYPES_HAS_FLOAT16
> +
> + // TODO: This would no longer be required if HdrGen let us guard function
> diff --git
> a/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
> b/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
> deleted file mode 100644
> index 493948acef..0000000000
> ---
> a/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
> +++ /dev/null
> @@ -1,274 +0,0 @@
> -From 82f18b02d9fec1bcc225a92251466ffee82f56b5 Mon Sep 17 00:00:00 2001
> -From: Khem Raj <raj.khem@gmail.com>
> -Date: Fri, 20 Mar 2026 14:22:17 -0700
> -Subject: [PATCH] [Clang] Rename UNUSED and UNKNOWN elements of
> OffloadArch enum to avoid
> - macro collisions
> -
> -OffloadArch uses enumerator named `UNUSED` `UNKNOWN`, which are common
> macro name
> -in external codebases (e.g. Mesa defines UNUSED as an attribute helper).
> If such
> -a macro is visible when including clang/Basic/OffloadArch.h, the
> preprocessor
> -expands the token inside the enum and breaks compilation of the installed
> Clang
> -headers.
> -
> -Rename the enumerator to `Unused` and `Unknown` and update all in-tree
> references. This is a
> -spelling-only change (no behavioral impact) and mirrors the existing
> approach
> -used for SM_32_ to avoid macro clashes.
> -
> -Upstream-Status: Backport [
> https://github.com/llvm/llvm-project/commit/5bc3d1966b2d0b300c338d85bb38e356f0d12a8c
> ]
> -Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> -
> -diff --git a/clang/include/clang/Basic/OffloadArch.h
> b/clang/include/clang/Basic/OffloadArch.h
> -index ea665b1..970487c 100644
> ---- a/clang/include/clang/Basic/OffloadArch.h
> -+++ b/clang/include/clang/Basic/OffloadArch.h
> -@@ -16,8 +16,8 @@ class StringRef;
> - namespace clang {
> -
> - enum class OffloadArch {
> --  UNUSED,
> --  UNKNOWN,
> -+  Unused,
> -+  Unknown,
> -   // TODO: Deprecate and remove GPU architectures older than sm_52.
> -   SM_20,
> -   SM_21,
> -@@ -145,7 +145,7 @@ const char *OffloadArchToString(OffloadArch A);
> - const char *OffloadArchToVirtualArchString(OffloadArch A);
> -
> - // Convert a string to an OffloadArch enum value. Returns
> --// OffloadArch::UNKNOWN if the string is not recognized.
> -+// OffloadArch::Unknown if the string is not recognized.
> - OffloadArch StringToOffloadArch(llvm::StringRef S);
> -
> - } // namespace clang
> -diff --git a/clang/lib/Basic/Cuda.cpp b/clang/lib/Basic/Cuda.cpp
> -index 514fa2f..7884910 100644
> ---- a/clang/lib/Basic/Cuda.cpp
> -+++ b/clang/lib/Basic/Cuda.cpp
> -@@ -75,7 +75,7 @@ CudaVersion ToCudaVersion(llvm::VersionTuple Version) {
> - }
> -
> - CudaVersion MinVersionForOffloadArch(OffloadArch A) {
> --  if (A == OffloadArch::UNKNOWN)
> -+  if (A == OffloadArch::Unknown)
> -     return CudaVersion::UNKNOWN;
> -
> -   // AMD GPUs do not depend on CUDA versions.
> -@@ -141,7 +141,7 @@ CudaVersion MaxVersionForOffloadArch(OffloadArch A) {
> -     return CudaVersion::NEW;
> -
> -   switch (A) {
> --  case OffloadArch::UNKNOWN:
> -+  case OffloadArch::Unknown:
> -     return CudaVersion::UNKNOWN;
> -   case OffloadArch::SM_20:
> -   case OffloadArch::SM_21:
> -diff --git a/clang/lib/Basic/OffloadArch.cpp
> b/clang/lib/Basic/OffloadArch.cpp
> -index 05177f1..f3bbe64 100644
> ---- a/clang/lib/Basic/OffloadArch.cpp
> -+++ b/clang/lib/Basic/OffloadArch.cpp
> -@@ -17,7 +17,7 @@ struct OffloadArchToStringMap {
> - #define GFX(gpu) {OffloadArch::GFX##gpu, "gfx" #gpu, "compute_amdgcn"}
> - static const OffloadArchToStringMap ArchNames[] = {
> -     // clang-format off
> --    {OffloadArch::UNUSED, "", ""},
> -+    {OffloadArch::Unused, "", ""},
> -     SM(20), {OffloadArch::SM_21, "sm_21", "compute_20"}, // Fermi
> -     SM(30), {OffloadArch::SM_32_, "sm_32", "compute_32"}, SM(35),
> SM(37),  // Kepler
> -     SM(50), SM(52), SM(53),          // Maxwell
> -@@ -132,7 +132,7 @@ OffloadArch StringToOffloadArch(llvm::StringRef S) {
> -         return S == Map.ArchName;
> -       });
> -   if (Result == std::end(ArchNames))
> --    return OffloadArch::UNKNOWN;
> -+    return OffloadArch::Unknown;
> -   return Result->Arch;
> - }
> -
> -diff --git a/clang/lib/Basic/Targets/NVPTX.cpp
> b/clang/lib/Basic/Targets/NVPTX.cpp
> -index 6526eef..9584f8a 100644
> ---- a/clang/lib/Basic/Targets/NVPTX.cpp
> -+++ b/clang/lib/Basic/Targets/NVPTX.cpp
> -@@ -64,7 +64,7 @@ NVPTXTargetInfo::NVPTXTargetInfo(const llvm::Triple
> &Triple,
> -   // Define available target features
> -   // These must be defined in sorted order!
> -   NoAsmVariants = true;
> --  GPU = OffloadArch::UNUSED;
> -+  GPU = OffloadArch::Unused;
> -
> -   // PTX supports f16 as a fundamental type.
> -   HasFastHalfType = true;
> -diff --git a/clang/lib/Basic/Targets/NVPTX.h
> b/clang/lib/Basic/Targets/NVPTX.h
> -index 9bd0cc3..eeffb0e 100644
> ---- a/clang/lib/Basic/Targets/NVPTX.h
> -+++ b/clang/lib/Basic/Targets/NVPTX.h
> -@@ -87,7 +87,7 @@ public:
> -   initFeatureMap(llvm::StringMap<bool> &Features, DiagnosticsEngine
> &Diags,
> -                  StringRef CPU,
> -                  const std::vector<std::string> &FeaturesVec) const
> override {
> --    if (GPU != OffloadArch::UNUSED)
> -+    if (GPU != OffloadArch::Unused)
> -       Features[OffloadArchToString(GPU)] = true;
> -     // Only add PTX feature if explicitly requested. Otherwise, let the
> backend
> -     // use the minimum required PTX version for the target SM.
> -@@ -146,7 +146,7 @@ public:
> -   }
> -
> -   bool isValidCPUName(StringRef Name) const override {
> --    return StringToOffloadArch(Name) != OffloadArch::UNKNOWN;
> -+    return StringToOffloadArch(Name) != OffloadArch::Unknown;
> -   }
> -
> -   void fillValidCPUList(SmallVectorImpl<StringRef> &Values) const
> override {
> -@@ -157,7 +157,7 @@ public:
> -
> -   bool setCPU(const std::string &Name) override {
> -     GPU = StringToOffloadArch(Name);
> --    return GPU != OffloadArch::UNKNOWN;
> -+    return GPU != OffloadArch::Unknown;
> -   }
> -
> -   void setSupportedOpenCLOpts() override {
> -diff --git a/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
> b/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
> -index db0d56d..f78047d 100644
> ---- a/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
> -+++ b/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
> -@@ -2266,15 +2266,15 @@ bool
> CGOpenMPRuntimeGPU::hasAllocateAttributeForGlobalVar(const VarDecl *VD,
> - // Get current OffloadArch and ignore any unknown values
> - static OffloadArch getOffloadArch(CodeGenModule &CGM) {
> -   if (!CGM.getTarget().hasFeature("ptx"))
> --    return OffloadArch::UNKNOWN;
> -+    return OffloadArch::Unknown;
> -   for (const auto &Feature : CGM.getTarget().getTargetOpts().FeatureMap)
> {
> -     if (Feature.getValue()) {
> -       OffloadArch Arch = StringToOffloadArch(Feature.getKey());
> --      if (Arch != OffloadArch::UNKNOWN)
> -+      if (Arch != OffloadArch::Unknown)
> -         return Arch;
> -     }
> -   }
> --  return OffloadArch::UNKNOWN;
> -+  return OffloadArch::Unknown;
> - }
> -
> - /// Check to see if target architecture supports unified addressing
> which is
> -@@ -2382,8 +2382,8 @@ void
> CGOpenMPRuntimeGPU::processRequiresDirective(const OMPRequiresDecl *D) {
> -       case OffloadArch::Generic:
> -       case OffloadArch::GRANITERAPIDS:
> -       case OffloadArch::BMG_G21:
> --      case OffloadArch::UNUSED:
> --      case OffloadArch::UNKNOWN:
> -+      case OffloadArch::Unused:
> -+      case OffloadArch::Unknown:
> -         break;
> -       case OffloadArch::LAST:
> -         llvm_unreachable("Unexpected GPU arch.");
> -diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Driver.cpp
> -index eb3f9cb..c8894a1 100644
> ---- a/clang/lib/Driver/Driver.cpp
> -+++ b/clang/lib/Driver/Driver.cpp
> -@@ -946,7 +946,7 @@ inferOffloadToolchains(Compilation &C,
> Action::OffloadKind Kind) {
> -   llvm::DenseSet<llvm::StringRef> Triples;
> -   for (llvm::StringRef Arch : Archs) {
> -     OffloadArch ID = StringToOffloadArch(Arch);
> --    if (ID == OffloadArch::UNKNOWN)
> -+    if (ID == OffloadArch::Unknown)
> -       ID = StringToOffloadArch(
> -           getProcessorFromTargetID(llvm::Triple("amdgcn-amd-amdhsa"),
> Arch));
> -
> -@@ -961,12 +961,12 @@ inferOffloadToolchains(Compilation &C,
> Action::OffloadKind Kind) {
> -       return llvm::DenseSet<llvm::StringRef>();
> -     }
> -     if (Kind == Action::OFK_OpenMP &&
> --        (ID == OffloadArch::UNKNOWN || ID == OffloadArch::UNUSED)) {
> -+        (ID == OffloadArch::Unknown || ID == OffloadArch::Unused)) {
> -
>  C.getDriver().Diag(clang::diag::err_drv_failed_to_deduce_target_from_arch)
> -           << Arch;
> -       return llvm::DenseSet<llvm::StringRef>();
> -     }
> --    if (ID == OffloadArch::UNKNOWN || ID == OffloadArch::UNUSED) {
> -+    if (ID == OffloadArch::Unknown || ID == OffloadArch::Unused) {
> -       C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
> -           << "offload" << Arch;
> -       return llvm::DenseSet<llvm::StringRef>();
> -@@ -3305,7 +3305,7 @@ class OffloadingActionBuilder final {
> -     bool Relocatable = false;
> -
> -     /// Default GPU architecture if there's no one specified.
> --    OffloadArch DefaultOffloadArch = OffloadArch::UNKNOWN;
> -+    OffloadArch DefaultOffloadArch = OffloadArch::Unknown;
> -
> -     /// Compilation unit ID specified by option '-fuse-cuid=' or'-cuid='.
> -     const CUIDOptions &CUIDOpts;
> -@@ -3407,7 +3407,7 @@ class OffloadingActionBuilder final {
> -
> -       // If we have a fat binary, add it to the list.
> -       if (CudaFatBinary) {
> --        AddTopLevel(CudaFatBinary, OffloadArch::UNUSED);
> -+        AddTopLevel(CudaFatBinary, OffloadArch::Unused);
> -         CudaDeviceActions.clear();
> -         CudaFatBinary = nullptr;
> -         return;
> -@@ -4669,12 +4669,12 @@ static StringRef
> getCanonicalArchString(Compilation &C,
> -   OffloadArch Arch =
> -       StringToOffloadArch(getProcessorFromTargetID(Triple, ArchStr));
> -   if (Triple.isNVPTX() &&
> --      (Arch == OffloadArch::UNKNOWN || !IsNVIDIAOffloadArch(Arch))) {
> -+      (Arch == OffloadArch::Unknown || !IsNVIDIAOffloadArch(Arch))) {
> -     C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
> -         << "CUDA" << ArchStr;
> -     return StringRef();
> -   } else if (Triple.isAMDGPU() &&
> --             (Arch == OffloadArch::UNKNOWN || !IsAMDOffloadArch(Arch))) {
> -+             (Arch == OffloadArch::Unknown || !IsAMDOffloadArch(Arch))) {
> -     C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
> -         << "HIP" << ArchStr;
> -     return StringRef();
> -diff --git a/clang/lib/Driver/OffloadBundler.cpp
> b/clang/lib/Driver/OffloadBundler.cpp
> -index f69ac41..6d446f2 100644
> ---- a/clang/lib/Driver/OffloadBundler.cpp
> -+++ b/clang/lib/Driver/OffloadBundler.cpp
> -@@ -95,7 +95,7 @@ OffloadTargetInfo::OffloadTargetInfo(const StringRef
> Target,
> -       Components.size() == 6 ? Components.back() : "";
> -   StringRef TargetId = TargetIdWithFeature.split(':').first;
> -   if (!TargetId.empty() &&
> --      clang::StringToOffloadArch(TargetId) !=
> clang::OffloadArch::UNKNOWN)
> -+      clang::StringToOffloadArch(TargetId) !=
> clang::OffloadArch::Unknown)
> -     this->TargetID = TargetIdWithFeature;
> -   else
> -     this->TargetID = "";
> -diff --git a/clang/lib/Driver/ToolChains/Cuda.cpp
> b/clang/lib/Driver/ToolChains/Cuda.cpp
> -index 6cc73ff..d97b926 100644
> ---- a/clang/lib/Driver/ToolChains/Cuda.cpp
> -+++ b/clang/lib/Driver/ToolChains/Cuda.cpp
> -@@ -319,7 +319,7 @@ void CudaInstallationDetector::AddCudaIncludeArgs(
> -
> - void CudaInstallationDetector::CheckCudaVersionSupportsArch(
> -     OffloadArch Arch) const {
> --  if (Arch == OffloadArch::UNKNOWN || Version == CudaVersion::UNKNOWN ||
> -+  if (Arch == OffloadArch::Unknown || Version == CudaVersion::UNKNOWN ||
> -       ArchsWithBadVersion[(int)Arch])
> -     return;
> -
> -@@ -408,7 +408,7 @@ void NVPTX::Assembler::ConstructJob(Compilation &C,
> const JobAction &JA,
> -
> -   // Obtain architecture from the action.
> -   OffloadArch gpu_arch = StringToOffloadArch(GPUArchName);
> --  assert(gpu_arch != OffloadArch::UNKNOWN &&
> -+  assert(gpu_arch != OffloadArch::Unknown &&
> -          "Device action expected to have an architecture.");
> -
> -   // Check that our installation's ptxas supports gpu_arch.
> -diff --git a/clang/lib/Sema/SemaDeclAttr.cpp
> b/clang/lib/Sema/SemaDeclAttr.cpp
> -index 3f0ea5c..e6d3516 100644
> ---- a/clang/lib/Sema/SemaDeclAttr.cpp
> -+++ b/clang/lib/Sema/SemaDeclAttr.cpp
> -@@ -5732,7 +5732,7 @@ Sema::CreateLaunchBoundsAttr(const
> AttributeCommonInfo &CI, Expr *MaxThreads,
> -   if (MaxBlocks) {
> -     // '.maxclusterrank' ptx directive requires .target sm_90 or higher.
> -     auto SM = getOffloadArch(Context.getTargetInfo());
> --    if (SM == OffloadArch::UNKNOWN || SM < OffloadArch::SM_90) {
> -+    if (SM == OffloadArch::Unknown || SM < OffloadArch::SM_90) {
> -       Diag(MaxBlocks->getBeginLoc(),
> diag::warn_cuda_maxclusterrank_sm_90)
> -           << OffloadArchToString(SM) << CI <<
> MaxBlocks->getSourceRange();
> -       // Ignore it by setting MaxBlocks to null;
> diff --git
> a/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
> b/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
> deleted file mode 100644
> index f458fd0cf8..0000000000
> ---
> a/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
> +++ /dev/null
> @@ -1,33 +0,0 @@
> -From 5dbd0a05f64a43849a7edde95a0e5f2323cd1f9d Mon Sep 17 00:00:00 2001
> -From: Khem Raj <khem.raj@oss.qualcomm.com>
> -Date: Tue, 31 Mar 2026 19:33:29 -0700
> -Subject: [PATCH] libcxxabi: declare __gnu_unwind_frame in cxa_personality
> -
> -ARM EHABI builds of libcxxabi fail with clang-22+ because
> -cxa_personality.cpp calls __gnu_unwind_frame without a visible
> -declaration, triggering:
> -
> -  error: use of undeclared identifier '__gnu_unwind_frame'
> -
> -Add an extern "C" forward declaration before the EHABI unwind helper
> -so the source compiles correctly.
> -
> -Upstream-Status: Submitted [
> https://github.com/llvm/llvm-project/pull/189787]
> -Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
> ----
> - libcxxabi/src/cxa_personality.cpp | 2 ++
> - 1 file changed, 2 insertions(+)
> -
> -diff --git a/libcxxabi/src/cxa_personality.cpp
> b/libcxxabi/src/cxa_personality.cpp
> -index 35f4e3807724..ddff277cc7b8 100644
> ---- a/libcxxabi/src/cxa_personality.cpp
> -+++ b/libcxxabi/src/cxa_personality.cpp
> -@@ -1116,6 +1116,8 @@ __gxx_personality_seh0(PEXCEPTION_RECORD ms_exc,
> void *this_frame,
> -
> - #else
> -
> -+extern "C" _Unwind_Reason_Code __gnu_unwind_frame(_Unwind_Exception*,
> -+                                                  _Unwind_Context*);
> - // Helper function to unwind one frame.
> - // ARM EHABI 7.3 and 7.4: If the personality function returns
> _URC_CONTINUE_UNWIND, the
> - // personality routine should update the virtual register set (VRS)
> according to the
> diff --git
> a/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
> b/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
> deleted file mode 100644
> index 39e27ac12f..0000000000
> ---
> a/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
> +++ /dev/null
> @@ -1,71 +0,0 @@
> -From 965f9d87adb0a7376454374fbc140ab69bd796a9 Mon Sep 17 00:00:00 2001
> -From: Florian Hahn <flo@fhahn.com>
> -Date: Fri, 27 Mar 2026 13:02:51 +0000
> -Subject: [PATCH] [LoopUnroll] Use MapVector for deterministic iteration
> order.
> - (#188821)
> -
> -NonLoopBlocksIDom determines the order we adjust the DT, impacting DRT
> -child ordering.
> -
> -Similarly, ExitInfos order impacts the order of SetDest, which applies
> -DT updates.
> -
> -The order impacts collectChildrenInLoop, which in turn impacts the we
> -process BBs in LICM. And this in turn impacts the order in which we
> -perform alias queries.
> -
> -If the order is not deterministic, we sometimes get different NumNoAlias
> -statistic counts, and possibly also different IR, although I have not
> -confirmed the latter.
> -
> -Upstream-Status: Backport [
> https://github.com/llvm/llvm-project/commit/965f9d87adb0a7376454374fbc140ab69bd796a9
> ]
> -Signed-off-by: Sunilkumar Dora <sunilkumar.dora@windriver.com>
> -Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
> -
> ----
> - llvm/lib/Transforms/Utils/LoopPeel.cpp   | 3 ++-
> - llvm/lib/Transforms/Utils/LoopUnroll.cpp | 3 ++-
> - 2 files changed, 4 insertions(+), 2 deletions(-)
> -
> -diff --git a/llvm/lib/Transforms/Utils/LoopPeel.cpp
> b/llvm/lib/Transforms/Utils/LoopPeel.cpp
> -index 91737b5c30533..4c67d5a9ae680 100644
> ---- a/llvm/lib/Transforms/Utils/LoopPeel.cpp
> -+++ b/llvm/lib/Transforms/Utils/LoopPeel.cpp
> -@@ -11,6 +11,7 @@
> -
> - #include "llvm/Transforms/Utils/LoopPeel.h"
> - #include "llvm/ADT/DenseMap.h"
> -+#include "llvm/ADT/MapVector.h"
> - #include "llvm/ADT/SmallVector.h"
> - #include "llvm/ADT/Statistic.h"
> - #include "llvm/Analysis/Loads.h"
> -@@ -1121,7 +1122,7 @@ void llvm::peelLoop(Loop *L, unsigned PeelCount,
> bool PeelLast, LoopInfo *LI,
> -   // later. Immediate dominator of such block might change, because we
> add more
> -   // routes which can lead to the exit: we can reach it from the peeled
> -   // iterations too.
> --  DenseMap<BasicBlock *, BasicBlock *> NonLoopBlocksIDom;
> -+  MapVector<BasicBlock *, BasicBlock *> NonLoopBlocksIDom;
> -   for (auto *BB : L->blocks()) {
> -     auto *BBDomNode = DT.getNode(BB);
> -     SmallVector<BasicBlock *, 16> ChildrenToUpdate;
> -diff --git a/llvm/lib/Transforms/Utils/LoopUnroll.cpp
> b/llvm/lib/Transforms/Utils/LoopUnroll.cpp
> -index 6a2ccbea996bf..ab35d217f0d93 100644
> ---- a/llvm/lib/Transforms/Utils/LoopUnroll.cpp
> -+++ b/llvm/lib/Transforms/Utils/LoopUnroll.cpp
> -@@ -17,6 +17,7 @@
> -
> - #include "llvm/ADT/ArrayRef.h"
> - #include "llvm/ADT/DenseMap.h"
> -+#include "llvm/ADT/MapVector.h"
> - #include "llvm/ADT/STLExtras.h"
> - #include "llvm/ADT/ScopedHashTable.h"
> - #include "llvm/ADT/SetVector.h"
> -@@ -515,7 +516,7 @@ llvm::UnrollLoop(Loop *L, UnrollLoopOptions ULO,
> LoopInfo *LI,
> -     BasicBlock *FirstExitingBlock = nullptr;
> -     SmallVector<BasicBlock *> ExitingBlocks;
> -   };
> --  DenseMap<BasicBlock *, ExitInfo> ExitInfos;
> -+  MapVector<BasicBlock *, ExitInfo> ExitInfos;
> -   SmallVector<BasicBlock *, 4> ExitingBlocks;
> -   L->getExitingBlocks(ExitingBlocks);
> -   for (auto *ExitingBlock : ExitingBlocks) {
> diff --git a/meta/recipes-devtools/clang/common-clang.inc
> b/meta/recipes-devtools/clang/common-clang.inc
> index 9018094419 <(901)%20809-4419>..5d571e5fce 100644
> --- a/meta/recipes-devtools/clang/common-clang.inc
> +++ b/meta/recipes-devtools/clang/common-clang.inc
> @@ -3,9 +3,9 @@ LLVM_DIR = "llvm${LLVM_RELEASE}"
>
>  LLVM_HTTP ?= "https://github.com/llvm"
>
> -MAJOR_VER = "22"
> +MAJOR_VER = "23"
>  MINOR_VER = "1"
> -PATCH_VER = "8"
> +PATCH_VER = "0"
>  # could be 'rcX' or 'git' or empty ( for release )
>  VER_SUFFIX = ""
>
> diff --git a/meta/recipes-devtools/clang/common.inc
> b/meta/recipes-devtools/clang/common.inc
> index e1e03872cd..0ca6951ff4 100644
> --- a/meta/recipes-devtools/clang/common.inc
> +++ b/meta/recipes-devtools/clang/common.inc
> @@ -17,51 +17,45 @@ BASEURI ?=
> "${LLVM_HTTP}/llvm-project/releases/download/llvmorg-${PV}${VER_SUFFI
>  UPSTREAM_CHECK_URI = "${LLVM_HTTP}/llvm-project/releases/"
>  UPSTREAM_CHECK_REGEX = "releases/tag/llvmorg-?(?P<pver>\d+(\.\d+)+)"
>  SOURCEDIR ?= "llvm-project-${PV}${VER_SUFFIX}.src"
> -SRC_URI[sha256sum] =
> "922f1817a0df7b1489272d18134ee0087a8b068828f87ac63b9861b1a9965888"
> +SRC_URI[sha256sum] =
> "ab1f0e3ec52448c33e8782eaf0422504b87c7b016b22514653ee0d8fcee479ff"
>
>  SRC_URI = "\
>      ${BASEURI} \
> -
> file://0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch \
> -    file://0002-compiler-rt-support-a-new-embedded-linux-target.patch \
> -
> file://0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch \
> -    file://0004-llvm-allow-env-override-of-exe-and-libdir-path.patch \
> -    file://0005-clang-driver-Check-sysroot-for-ldso-path.patch \
> -    file://0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch \
> -    file://0007-clang-Prepend-trailing-to-sysroot.patch \
> -    file://0009-clang-Define-releative-gcc-installation-dir.patch \
> -
> file://0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch \
> -    file://0011-Check-for-atomic-double-intrinsics.patch \
> -    file://0012-cmake-Fix-configure-for-packages-using-find_package.patch
> \
> -
> file://0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch \
> -
> file://0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch \
> -    file://0015-clang-Use-python3-in-python-scripts.patch \
> -
> file://0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch \
> -
> file://0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch \
> -
> file://0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch \
> -    file://0019-libunwind-Added-unw_backtrace-method.patch \
> -    file://0020-lldb-Link-with-libatomic-on-x86.patch \
> -    file://0021-compiler-rt-Enable-__int128-for-ppc32.patch \
> -    file://0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch \
> -    file://0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch \
> -    file://0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch \
> -    file://0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch \
> -    file://0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch \
> -
> file://0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch \
> -    file://0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch \
> -
> file://0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch \
> -    file://0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> \
> -
> file://0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch \
> -
> file://0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch \
> -
> file://0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch \
> -
> file://0035-Prevent-revisiting-block-when-searching-for-noreturn.patch \
> -
> file://0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch \
> -
> file://0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch \
> -
> file://0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch \
> -
> file://0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch \
> -
> file://0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch \
> -
> file://0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch \
> -    file://0042-guard-clang-tools-extra-test.patch \
> -
> file://0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch \
> +
> file://0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch \
> +    file://0002-llvm-allow-env-override-of-exe-and-libdir-path.patch \
> +    file://0003-clang-driver-Check-sysroot-for-ldso-path.patch \
> +    file://0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch \
> +    file://0005-clang-Prepend-trailing-to-sysroot.patch \
> +    file://0006-clang-Define-releative-gcc-installation-dir.patch \
> +
> file://0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch \
> +    file://0008-Check-for-atomic-double-intrinsics.patch \
> +    file://0009-cmake-Fix-configure-for-packages-using-find_package.patch
> \
> +
> file://0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch \
> +
> file://0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch \
> +    file://0012-clang-Use-python3-in-python-scripts.patch \
> +
> file://0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch \
> +
> file://0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch \
> +    file://0015-libunwind-Added-unw_backtrace-method.patch \
> +    file://0016-lldb-Link-with-libatomic-on-x86.patch \
> +    file://0017-compiler-rt-Enable-__int128-for-ppc32.patch \
> +    file://0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch \
> +    file://0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch \
> +    file://0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch \
> +    file://0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch \
> +    file://0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch \
> +
> file://0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch \
> +    file://0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch \
> +
> file://0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch \
> +    file://0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> \
> +
> file://0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch \
> +    file://0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch \
> +
> file://0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch \
> +
> file://0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch \
> +    file://0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch \
> +
> file://0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch \
> +
> file://0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch \
> +    file://0034-guard-clang-tools-extra-test.patch \
> +    file://0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch \
>  "
>  # Fallback to no-PIE if not set
>  GCCPIE ??= ""
> --
> 2.43.0
>
>

[-- Attachment #2: Type: text/html, Size: 163404 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
  2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
                   ` (10 preceding siblings ...)
  2026-08-30 12:58 ` [PATCH 11/11] clang/llvm: Ignore tests fail with clang/llvm 23 upgrade sunilkumar.dora
@ 2026-08-30 19:53 ` Khem Raj
  2026-09-01  4:59   ` [OE-core] " Dora, Sunil Kumar
  11 siblings, 1 reply; 30+ messages in thread
From: Khem Raj @ 2026-08-30 19:53 UTC (permalink / raw)
  To: sunilkumar.dora
  Cc: openembedded-core, randy.macleod, sundeep.kokkonda,
	deepesh.vatharaj

[-- Attachment #1: Type: text/plain, Size: 13570 bytes --]

Looks pretty good to me. I have few feedback comments, not a merge blocker
but good to consider for future ease of porting.

On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:

> From: Sunil Dora <sunilkumar.dora@windriver.com>
>
> This upgrades clang/llvm from 22.1.8 to 23.1.0 and fixes the fallout
> found while testing the result.
>
> The carried LLVM patch stack goes from 41 to 35: seven dropped
> because 23.1.0 already contains the fix or the code they patched no
> longer exists, three reworked for LLVM 23, and one added for a 32-bit
> x86 build break, already merged in llvm-project.
>
> Please apply with git am --keep-cr: patch 8 fixes an ovmf file that
> uses CRLF line endings, and plain git am corrupts the patch.
>
> I have also reported the underlying bugs upstream:
>   llvm float16 fix, merged:
>     https://github.com/llvm/llvm-project/pull/219675
>   ovmf fix, sent to edk2:
>     https://github.com/tianocore/edk2/pull/13038
>   pango warning, the root cause is in GLib, reported to both:
>     https://gitlab.gnome.org/GNOME/glib/-/issues/4038
>     https://gitlab.gnome.org/GNOME/pango/-/issues/900
>   vulkan-samples warning, which is a real bug in their code:
>     https://github.com/KhronosGroup/Vulkan-Samples/issues/1570
>
> Tested: oe-selftest clang suites on qemuarm, qemuarm64, qemux86,
> qemux86-64 and qemuriscv64 on the autobuilder, musl images on qemux86
> and qemuarm64, a qemux86 world build with TOOLCHAIN=clang, 32-bit
> multilib, and core-image-minimal testimage runs.
>
> Deepesh Varatharajan (2):
>   rust: Fix build and oe-selftest failures with LLVM 23
>   clang/llvm: Ignore tests fail with clang/llvm 23 upgrade
>
> Sunil Dora (9):
>   clang/llvm: Upgrade to 23.1.0 release
>   spirv-llvm-translator: Upgrade to 23.1.0
>   openmp: Build via the LLVM runtimes entry point
>   rust: Do not pass the removed x86 amx-tf32 feature to LLVM 23
>   clang: Disable clangd's decision-forest completion model on powerpc
>   pango: Don't turn clang 23's -Wunused-but-set-global into an error
>   ovmf: Fix memcpy alias prototype for clang 23
>   vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error
>   gettext: Export a fully-flagged Objective-C compiler
>
>  meta/conf/distro/include/maintainers.inc      |   2 +-
>  meta/lib/oeqa/selftest/cases/clang.py         |  10 +
>  meta/lib/oeqa/selftest/cases/rust.py          |   1 +
>  ...t-env.in-do-not-add-C-CXX-parameters.patch |  17 +-
>  meta/recipes-core/gettext/gettext_1.0.bb      |   5 +
>  ...sicLib-fix-memcpy-alias-prototype-fo.patch |  35 +
>  meta/recipes-core/ovmf/ovmf_git.bb            |   1 +
>  ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
>  ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 --
>  ...-support-a-new-embedded-linux-target.patch | 309 --------
>  ...env-override-of-exe-and-libdir-path.patch} |   4 +-
>  ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
>  ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
>  ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
>  ...fine-releative-gcc-installation-dir.patch} |  10 +-
>  ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
>  ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
>  ...ure-for-packages-using-find_package.patch} |  20 +-
>  ...e-dir-location-for-cross-toolchains.patch} |   4 +-
>  ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
>  ...clang-Use-python3-in-python-scripts.patch} |   6 +-
>  ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +-
>  ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
>  ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
>  ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
>  ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 --
>  ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
>  ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
>  ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
>  ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
>  ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 +-
>  ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
>  ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
>  ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
>  ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
>  ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
>  ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
>  ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
>  ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
>  ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
>  ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
>  ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
>  ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
>  ...> 0034-guard-clang-tools-extra-test.patch} |  47 +-
>  ...ng-block-when-searching-for-noreturn.patch |  41 --
>  ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 +
>  ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 --------
>  ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 -
>  ...te-exit-fold-candidates-in-determini.patch |  71 --
>  meta/recipes-devtools/clang/clang_git.bb      |   4 +
>  meta/recipes-devtools/clang/common-clang.inc  |   4 +-
>  meta/recipes-devtools/clang/common.inc        |  78 +--
>  meta/recipes-devtools/clang/openmp_git.bb     |   5 +-
>  ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
>  ...llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch |  38 +
>  meta/recipes-devtools/rust/rust-source.inc    |   2 +
>  ...ror-on-clang-s-unused-but-set-global.patch |  28 +
>  meta/recipes-graphics/pango/pango_1.58.0.bb   |   1 +
>  ...1.5.bb => spirv-llvm-translator_23.1.0.bb} |   6 +-
>  .../vulkan/vulkan-samples_git.bb              |   4 +-
>  60 files changed, 1109 insertions(+), 1113 deletions(-)
>  create mode 100644
> meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch
>  rename
> meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
> => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
>  rename
> meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
> => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
>  rename
> meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch
> => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
>  rename
> meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
> => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch
> => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
>  rename
> meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch
> => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
>  rename
> meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
> => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch
> => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch
> => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
>  rename
> meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
> => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
>  rename
> meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
> => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
>  rename
> meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch
> => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
>  rename
> meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
> => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
> => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch
> => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
>  rename
> meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch
> => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
>  rename
> meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch
> => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
>  rename
> meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
> => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
> => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
> => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
>  rename
> meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
> => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
>  rename
> meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
> => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
>  rename
> meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
> => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
>  rename
> meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
> => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
> => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
>  rename
> meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
> => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
>  rename
> meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
> => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
>  rename
> meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
> => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
> => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
>  rename
> meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
> => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
>  rename
> meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
> => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
>  rename
> meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
> => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
>  rename
> meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
> => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
>  rename
> meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch
> => 0034-guard-clang-tools-extra-test.patch} (83%)
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
>  create mode 100644
> meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
>  delete mode 100644
> meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
>  create mode 100644
> meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>  create mode 100644
> meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch
>  create mode 100644
> meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
>  rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb =>
> spirv-llvm-translator_23.1.0.bb} (87%)
>
> --
> 2.43.0
>
>

[-- Attachment #2: Type: text/html, Size: 15645 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release
  2026-08-30 19:53   ` Khem Raj
@ 2026-09-01  3:37     ` Dora, Sunil Kumar
  2026-09-01 12:49       ` Richard Purdie
  0 siblings, 1 reply; 30+ messages in thread
From: Dora, Sunil Kumar @ 2026-09-01  3:37 UTC (permalink / raw)
  To: raj.khem@gmail.com
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 142030 bytes --]

On 8/31/2026 1:22 AM, Khem Raj via lists.openembedded.org wrote:
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.


On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>> wrote:
From: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>

Rebase the OE patch stack from 22.1.8 onto the 23.x release branch.

Dropped, the fix is already in 23.1.0:
  compiler-rt: do not use backtrace APIs on non-glibc linux
    https://github.com/llvm/llvm-project/commit/252ad2052409
  Rename UNUSED and UNKNOWN elements of OffloadArch enum
    https://github.com/llvm/llvm-project/commit/82f18b02d9fe
  libcxxabi: declare __gnu_unwind_frame in cxa_personality
    https://github.com/llvm/llvm-project/commit/8119f1854948
  LoopUnroll: iterate exit fold candidates in deterministic order
    https://github.com/llvm/llvm-project/commit/965f9d87adb0
  Prevent revisiting block when searching for noreturn
    https://github.com/llvm/llvm-project/commit/330b40e11fd2

Dropped, obsolete:
  libcxxabi: find libunwind headers when LIBCXXABI_LIBUNWIND_INCLUDES
    (cmake's find_path now searches the user-supplied path first)
  compiler-rt: support a new embedded linux target
    (only added files for the long-removed Makefile build system)

Reworked for the TripleName.def triple string tables added in 23:
  llvm/clang: insert anchor for adding OE distro vendor
  clang/llvm: add OE specific ABI triple for N32 ABI

Reworked for the restructured powerpc source lists in compiler-rt:
  compiler-rt: enable __int128 for ppc32

Newly carried, already merged in LLVM main:
  libc: disable float16 on 32-bit x86 without SSE2
    https://github.com/llvm/llvm-project/commit/05da143c63d3

GCC 16 defines __FLT16_MANT_DIG__ when targeting i686 without SSE2,
so the llvm-libc float16 headers that APFloat.cpp now includes fail
to build for 32-bit x86 multilib ("SSE register return with SSE2
disabled") without that last patch.

Release notes: https://releases.llvm.org/23.1.0/docs/ReleaseNotes.html

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>
---
 meta/conf/distro/include/maintainers.inc      |   2 +-
 ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
 ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 ----
 ...-support-a-new-embedded-linux-target.patch | 309 ------------------
 ...env-override-of-exe-and-libdir-path.patch} |   4 +-
 ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
 ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
 ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
 ...fine-releative-gcc-installation-dir.patch} |  10 +-
 ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
 ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
 ...ure-for-packages-using-find_package.patch} |  20 +-
 ...e-dir-location-for-cross-toolchains.patch} |   4 +-
 ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
 ...clang-Use-python3-in-python-scripts.patch} |   6 +-
 ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +--
 ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
 ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
 ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
 ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 ----
 ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
 ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
 ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
 ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
 ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 ++--
 ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
 ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
 ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
 ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
 ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
 ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
 ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
 ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
 ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
 ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
 ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
 ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
 ...> 0034-guard-clang-tools-extra-test.patch} |  47 ++-
 ...ng-block-when-searching-for-noreturn.patch |  41 ---
 ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 ++
 ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 ----------------
 ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 --
 ...te-exit-fold-candidates-in-determini.patch |  71 ----
 meta/recipes-devtools/clang/common-clang.inc  |   4 +-
 meta/recipes-devtools/clang/common.inc        |  78 ++---
 45 files changed, 302 insertions(+), 1102 deletions(-)
 rename meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
 rename meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
 rename meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
 rename meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
 rename meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
 rename meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
 rename meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
 rename meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
 rename meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
 rename meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
 rename meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
 rename meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch => 0034-guard-clang-tools-extra-test.patch} (83%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
 create mode 100644 meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch

diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
index 2966cddc05..dde6821718 100644
--- a/meta/conf/distro/include/maintainers.inc
+++ b/meta/conf/distro/include/maintainers.inc
@@ -482,7 +482,7 @@ RECIPE_MAINTAINER:pn-linux-yocto-tiny = "Bruce Ashfield <bruce.ashfield@gmail.co<mailto:bruce.ashfield@gmail.co>
 RECIPE_MAINTAINER:pn-lld = "Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>"
 RECIPE_MAINTAINER:pn-lldb = "Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>"
 RECIPE_MAINTAINER:pn-llvm = "Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>"
-RECIPE_MAINTAINER:pn-llvm-project-source-22.1.8 = "Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>"
+RECIPE_MAINTAINER:pn-llvm-project-source-23.1.0 = "Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>"
 RECIPE_MAINTAINER:pn-llvm-tblgen-native = "Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>"
 RECIPE_MAINTAINER:pn-log4cplus = "Unassigned <unassigned@yoctoproject.org<mailto:unassigned@yoctoproject.org>>"
 RECIPE_MAINTAINER:pn-logrotate = "Yi Zhao <yi.zhao@windriver.com<mailto:yi.zhao@windriver.com>>"
diff --git a/meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch b/meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
similarity index 90%
rename from meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
rename to meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
index 896bbd11aa..4684fff493 100644
--- a/meta/recipes-devtools/clang/clang/0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
+++ b/meta/recipes-devtools/clang/clang/0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
@@ -1,4 +1,4 @@
-From 16b03fccab20cac13065ab99f36a7f0a77a62b92 Mon Sep 17 00:00:00 2001
+From 09798ecb4d4c7f1372e7538666bf9c5199f7ab04 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Thu, 19 May 2016 23:11:45 -0700
 Subject: [PATCH] compiler-rt: Simplify cross-compilation. Don't use
@@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 10 insertions(+), 1 deletion(-)

 diff --git a/compiler-rt/CMakeLists.txt b/compiler-rt/CMakeLists.txt
-index a92258ae1244..98c4e9a681d5 100644
+index d720b86..60ac56f 100644
 --- a/compiler-rt/CMakeLists.txt
 +++ b/compiler-rt/CMakeLists.txt
-@@ -109,7 +109,16 @@ if (COMPILER_RT_STANDALONE_BUILD)
+@@ -125,7 +125,16 @@ if (COMPILER_RT_STANDALONE_BUILD)
    set(CMAKE_CXX_EXTENSIONS NO)

    if (NOT LLVM_RUNTIMES_BUILD)
diff --git a/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch b/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
deleted file mode 100644
index 43221274bf..0000000000
--- a/meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 97247b6a1df63a5f930d090a3952876eb67cf6fb Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
-Date: Sun, 27 Aug 2017 10:37:49 -0700
-Subject: [PATCH] libcxxabi: Find libunwind headers when
- LIBCXXABI_LIBUNWIND_INCLUDES is set
-
-Currently, when LIBCXXABI_LIBUNWIND_INCLUDES is set via CMake arguments
-then it ends up not searching the specified dir and unwind.h is not found
-especially for ARM targets
-
-This patch makes the searching synthesized directories and then set
-LIBCXXABI_LIBUNWIND_INCLUDES if its there in environment
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
----
- libcxxabi/CMakeLists.txt | 15 ++++++++++-----
- 1 file changed, 10 insertions(+), 5 deletions(-)
-
-diff --git a/libcxxabi/CMakeLists.txt b/libcxxabi/CMakeLists.txt
-index 2b67c5972339..45d84b404b30 100644
---- a/libcxxabi/CMakeLists.txt
-+++ b/libcxxabi/CMakeLists.txt
-@@ -476,7 +476,7 @@ set(LIBCXXABI_LIBUNWIND_PATH "${LIBCXXABI_LIBUNWIND_PATH}" CACHE PATH
-     "Specify path to libunwind source." FORCE)
-
- if (LIBCXXABI_USE_LLVM_UNWINDER OR LLVM_NATIVE_ARCH MATCHES ARM)
--  find_path(LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL libunwind.h
-+  find_path(LIBCXXABI_LIBUNWIND_INCLUDES libunwind.h
-     PATHS ${LIBCXXABI_LIBUNWIND_INCLUDES}
-           ${LIBCXXABI_LIBUNWIND_PATH}/include
-           ${CMAKE_BINARY_DIR}/${LIBCXXABI_LIBUNWIND_INCLUDES}
-@@ -487,18 +487,23 @@ if (LIBCXXABI_USE_LLVM_UNWINDER OR LLVM_NATIVE_ARCH MATCHES ARM)
-     NO_CMAKE_FIND_ROOT_PATH
-   )
-
--  if (LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL STREQUAL "LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL-NOTFOUND")
--    set(LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL "")
-+  if (LIBCXXABI_LIBUNWIND_INCLUDES STREQUAL "LIBCXXABI_LIBUNWIND_INCLUDES-NOTFOUND")
-+    set(LIBCXXABI_LIBUNWIND_INCLUDES "")
-   endif()
- endif()
-
--if (NOT "${LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL}" STREQUAL "")
--  include_directories("${LIBCXXABI_LIBUNWIND_INCLUDES_INTERNAL}")
-+if (NOT "${LIBCXXABI_LIBUNWIND_INCLUDES}" STREQUAL "")
-+  include_directories("${LIBCXXABI_LIBUNWIND_INCLUDES}")
- endif()
-
- add_custom_target(cxxabi-test-depends
-   COMMENT "Build dependencies required to run the libc++abi test suite.")
-
-+set(LIBCXXABI_LIBUNWIND_INCLUDES "${LIBCXXABI_LIBUNWIND_INCLUDES}" CACHE PATH
-+    "Specify path to libunwind includes." FORCE)
-+set(LIBCXXABI_LIBUNWIND_PATH "${LIBCXXABI_LIBUNWIND_PATH}" CACHE PATH
-+    "Specify path to libunwind source." FORCE)
-+
- # Add source code. This also contains all of the logic for deciding linker flags
- # soname, etc...
- add_subdirectory(include)
diff --git a/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch b/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
deleted file mode 100644
index 5dcad6b0df..0000000000
--- a/meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
+++ /dev/null
@@ -1,309 +0,0 @@
-From eae63772aacba29de729d9af5c52542cd8a043ee Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
-Date: Sun, 19 Apr 2015 15:16:23 -0700
-Subject: [PATCH] compiler-rt: support a new embedded linux target
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
----
- .../make/platform/clang_linux_embedded.mk<http://clang_linux_embedded.mk>     | 286 ++++++++++++++++++
- .../clang_linux_embedded_test_input.c         |   0
- 2 files changed, 286 insertions(+)
- create mode 100644 compiler-rt/make/platform/clang_linux_embedded.mk<http://clang_linux_embedded.mk>
- create mode 100644 compiler-rt/make/platform/clang_linux_embedded_test_input.c
-
-diff --git a/compiler-rt/make/platform/clang_linux_embedded.mk<http://clang_linux_embedded.mk> b/compiler-rt/make/platform/clang_linux_embedded.mk<http://clang_linux_embedded.mk>
-new file mode 100644
-index 000000000000..d0a890075a1c
---- /dev/null
-+++ b/compiler-rt/make/platform/clang_linux_embedded.mk<http://clang_linux_embedded.mk>
-@@ -0,0 +1,286 @@
-+# These are the functions which clang needs when it is targeting a previous
-+# version of the OS. The issue is that the backend may use functions which were
-+# not present in the libgcc that shipped on the platform. In such cases, we link
-+# with a version of the library which contains private_extern definitions of all
-+# the extra functions which might be referenced.
-+
-+Description := Static runtime libraries for embedded clang/Linux
-+
-+# A function that ensures we don't try to build for architectures that we
-+# don't have working toolchains for.
-+CheckArches = \
-+  $(shell \
-+    result=""; \
-+    for arch in $(1); do \
-+      if $(CC) -arch $$arch -c \
-+        -integrated-as \
-+        $(ProjSrcRoot)/make/platform/clang_linux_embedded_test_input.c \
-+        -o /dev/null > /dev/null 2> /dev/null; then \
-+        result="$$result$$arch "; \
-+      else \
-+      printf 1>&2 \
-+        "warning: clang_linux_embedded.mk<http://clang_linux_embedded.mk>: dropping arch '$$arch' from lib '$(2)'\n"; \
-+      fi; \
-+    done; \
-+    echo $$result)
-+
-+XCRun = \
-+  $(shell \
-+    result=`xcrun -find $(1) 2> /dev/null`; \
-+    if [ "$$?" != "0" ]; then result=$(1); fi; \
-+    echo $$result)
-+
-+###
-+
-+CC       := $(call XCRun,clang)
-+AR       := $(call XCRun,ar)
-+RANLIB   := $(call XCRun,ranlib)
-+STRIP    := $(call XCRun,strip)
-+LIPO     := $(call XCRun,lipo)
-+DSYMUTIL := $(call XCRun,dsymutil)
-+Configs :=
-+UniversalArchs :=
-+
-+# Soft-float version of the runtime. No floating-point instructions will be used
-+# and the ABI (out of necessity) passes floating values in normal registers:
-+# non-VFP variant of the AAPCS.
-+UniversalArchs.soft_static := $(call CheckArches,arm armv7m armv7em armv7,soft_static)
-+Configs += $(if $(UniversalArchs.soft_static),soft_static)
-+
-+# Hard-float version of the runtime. On ARM VFP instructions and registers are
-+# allowed, and floating point values get passed in them. VFP variant of the
-+# AAPCS.
-+UniversalArchs.hard_static := $(call CheckArches,armv7em armv7 i386 x86_64,hard_static)
-+Configs += $(if $(UniversalArchs.hard_static),hard_static)
-+
-+UniversalArchs.soft_pic := $(call CheckArches,armv6m armv7m armv7em armv7,soft_pic)
-+Configs += $(if $(UniversalArchs.soft_pic),soft_pic)
-+
-+UniversalArchs.hard_pic := $(call CheckArches,armv7em armv7 i386 x86_64,hard_pic)
-+Configs += $(if $(UniversalArchs.hard_pic),hard_pic)
-+
-+CFLAGS := -Wall -Werror -Oz -fomit-frame-pointer -ffreestanding
-+
-+PIC_CFLAGS := -fPIC
-+STATIC_CFLAGS := -static
-+
-+CFLAGS_SOFT := -mfloat-abi=soft
-+CFLAGS_HARD := -mfloat-abi=hard
-+
-+CFLAGS_I386  := -march=pentium
-+
-+CFLAGS.soft_static := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_SOFT)
-+CFLAGS.hard_static := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_HARD)
-+CFLAGS.soft_pic    := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_SOFT)
-+CFLAGS.hard_pic    := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_HARD)
-+
-+CFLAGS.soft_static.armv7 := $(CFLAGS.soft_static) $(CFLAGS_ARMV7)
-+CFLAGS.hard_static.armv7 := $(CFLAGS.hard_static) $(CFLAGS_ARMV7)
-+CFLAGS.soft_pic.armv7    := $(CFLAGS.soft_pic) $(CFLAGS_ARMV7)
-+CFLAGS.hard_pic.armv7    := $(CFLAGS.hard_pic) $(CFLAGS_ARMV7)
-+
-+# x86 platforms ignore -mfloat-abi options and complain about doing so. Despite
-+# this they're hard-float.
-+CFLAGS.hard_static.i386   := $(CFLAGS) $(STATIC_CFLAGS) $(CFLAGS_I386)
-+CFLAGS.hard_pic.i386      := $(CFLAGS) $(PIC_CFLAGS) $(CFLAGS_I386)
-+CFLAGS.hard_static.x86_64 := $(CFLAGS) $(STATIC_CFLAGS)
-+CFLAGS.hard_pic.x86_64    := $(CFLAGS) $(PIC_CFLAGS)
-+
-+# Functions not wanted:
-+#   + eprintf is obsolete anyway
-+#   + *vfp: designed for Thumb1 CPUs with VFPv2
-+
-+COMMON_FUNCTIONS := \
-+      absvdi2 \
-+      absvsi2 \
-+      addvdi3 \
-+      addvsi3 \
-+      ashldi3 \
-+      ashrdi3 \
-+      bswapdi2 \
-+      bswapsi2 \
-+      clzdi2 \
-+      clzsi2 \
-+      cmpdi2 \
-+      ctzdi2 \
-+      ctzsi2 \
-+      divdc3 \
-+      divdi3 \
-+      divsc3 \
-+      divmodsi4 \
-+      udivmodsi4 \
-+      do_global_dtors \
-+      ffsdi2 \
-+      fixdfdi \
-+      fixsfdi \
-+      fixunsdfdi \
-+      fixunsdfsi \
-+      fixunssfdi \
-+      fixunssfsi \
-+      floatdidf \
-+      floatdisf \
-+      floatundidf \
-+      floatundisf \
-+      gcc_bcmp \
-+      lshrdi3 \
-+      moddi3 \
-+      muldc3 \
-+      muldi3 \
-+      mulsc3 \
-+      mulvdi3 \
-+      mulvsi3 \
-+      negdi2 \
-+      negvdi2 \
-+      negvsi2 \
-+      paritydi2 \
-+      paritysi2 \
-+      popcountdi2 \
-+      popcountsi2 \
-+      powidf2 \
-+      powisf2 \
-+      subvdi3 \
-+      subvsi3 \
-+      ucmpdi2 \
-+      udiv_w_sdiv \
-+      udivdi3 \
-+      udivmoddi4 \
-+      umoddi3 \
-+      adddf3 \
-+      addsf3 \
-+      cmpdf2 \
-+      cmpsf2 \
-+      div0 \
-+      divdf3 \
-+      divsf3 \
-+      divsi3 \
-+      extendsfdf2 \
-+      ffssi2 \
-+      fixdfsi \
-+      fixsfsi \
-+      floatsidf \
-+      floatsisf \
-+      floatunsidf \
-+      floatunsisf \
-+      comparedf2 \
-+      comparesf2 \
-+      modsi3 \
-+      muldf3 \
-+      mulsf3 \
-+      negdf2 \
-+      negsf2 \
-+      subdf3 \
-+      subsf3 \
-+      truncdfsf2 \
-+      udivsi3 \
-+      umodsi3 \
-+      unorddf2 \
-+      unordsf2
-+
-+ARM_FUNCTIONS := \
-+      aeabi_cdcmpeq \
-+      aeabi_cdrcmple \
-+      aeabi_cfcmpeq \
-+      aeabi_cfrcmple \
-+      aeabi_dcmpeq \
-+      aeabi_dcmpge \
-+      aeabi_dcmpgt \
-+      aeabi_dcmple \
-+      aeabi_dcmplt \
-+      aeabi_drsub \
-+      aeabi_fcmpeq \
-+      aeabi_fcmpge \
-+      aeabi_fcmpgt \
-+      aeabi_fcmple \
-+      aeabi_fcmplt \
-+      aeabi_frsub \
-+      aeabi_idivmod \
-+      aeabi_uidivmod \
-+
-+# ARM Assembly implementation which requires Thumb2 (i.e. won't work on v6M).
-+THUMB2_FUNCTIONS := \
-+      switch16 \
-+      switch32 \
-+      switch8 \
-+      switchu8 \
-+      sync_fetch_and_add_4 \
-+      sync_fetch_and_sub_4 \
-+      sync_fetch_and_and_4 \
-+      sync_fetch_and_or_4 \
-+      sync_fetch_and_xor_4 \
-+      sync_fetch_and_nand_4 \
-+      sync_fetch_and_max_4 \
-+      sync_fetch_and_umax_4 \
-+      sync_fetch_and_min_4 \
-+      sync_fetch_and_umin_4 \
-+      sync_fetch_and_add_8 \
-+      sync_fetch_and_sub_8 \
-+      sync_fetch_and_and_8 \
-+      sync_fetch_and_or_8 \
-+      sync_fetch_and_xor_8 \
-+      sync_fetch_and_nand_8 \
-+      sync_fetch_and_max_8 \
-+      sync_fetch_and_umax_8 \
-+      sync_fetch_and_min_8 \
-+      sync_fetch_and_umin_8
-+
-+I386_FUNCTIONS :=  \
-+      i686.get_pc_thunk.eax \
-+      i686.get_pc_thunk.ebp \
-+      i686.get_pc_thunk.ebx \
-+      i686.get_pc_thunk.ecx \
-+      i686.get_pc_thunk.edi \
-+      i686.get_pc_thunk.edx \
-+      i686.get_pc_thunk.esi
-+
-+# FIXME: Currently, compiler-rt is missing implementations for a number of the
-+# functions. Filter them out for now.
-+MISSING_FUNCTIONS := \
-+      cmpdf2 cmpsf2 div0 \
-+      ffssi2 \
-+      udiv_w_sdiv unorddf2 unordsf2 bswapdi2 \
-+      bswapsi2 \
-+      gcc_bcmp \
-+      do_global_dtors \
-+      i686.get_pc_thunk.eax i686.get_pc_thunk.ebp i686.get_pc_thunk.ebx \
-+      i686.get_pc_thunk.ecx i686.get_pc_thunk.edi i686.get_pc_thunk.edx \
-+      i686.get_pc_thunk.esi \
-+      aeabi_cdcmpeq aeabi_cdrcmple aeabi_cfcmpeq aeabi_cfrcmple aeabi_dcmpeq \
-+      aeabi_dcmpge aeabi_dcmpgt aeabi_dcmple aeabi_dcmplt aeabi_drsub \
-+      aeabi_fcmpeq \ aeabi_fcmpge aeabi_fcmpgt aeabi_fcmple aeabi_fcmplt \
-+      aeabi_frsub aeabi_idivmod aeabi_uidivmod
-+
-+FUNCTIONS_ARMV6M  := $(COMMON_FUNCTIONS) $(ARM_FUNCTIONS)
-+FUNCTIONS_ARM_ALL := $(COMMON_FUNCTIONS) $(ARM_FUNCTIONS) $(THUMB2_FUNCTIONS)
-+FUNCTIONS_I386    := $(COMMON_FUNCTIONS) $(I386_FUNCTIONS)
-+FUNCTIONS_X86_64  := $(COMMON_FUNCTIONS)
-+
-+FUNCTIONS_ARMV6M := \
-+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_ARMV6M))
-+FUNCTIONS_ARM_ALL := \
-+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_ARM_ALL))
-+FUNCTIONS_I386 := \
-+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_I386))
-+FUNCTIONS_X86_64 := \
-+      $(filter-out $(MISSING_FUNCTIONS),$(FUNCTIONS_X86_64))
-+
-+FUNCTIONS.soft_static.armv6m := $(FUNCTIONS_ARMV6M)
-+FUNCTIONS.soft_pic.armv6m    := $(FUNCTIONS_ARMV6M)
-+
-+FUNCTIONS.soft_static.armv7m := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.soft_pic.armv7m    := $(FUNCTIONS_ARM_ALL)
-+
-+FUNCTIONS.soft_static.armv7em := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_static.armv7em := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.soft_pic.armv7em    := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_pic.armv7em    := $(FUNCTIONS_ARM_ALL)
-+
-+FUNCTIONS.soft_static.armv7 := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_static.armv7 := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.soft_pic.armv7    := $(FUNCTIONS_ARM_ALL)
-+FUNCTIONS.hard_pic.armv7    := $(FUNCTIONS_ARM_ALL)
-+
-+FUNCTIONS.hard_static.i386 := $(FUNCTIONS_I386)
-+FUNCTIONS.hard_pic.i386    := $(FUNCTIONS_I386)
-+
-+FUNCTIONS.hard_static.x86_64 := $(FUNCTIONS_X86_64)
-+FUNCTIONS.hard_pic.x86_64    := $(FUNCTIONS_X86_64)
-diff --git a/compiler-rt/make/platform/clang_linux_embedded_test_input.c b/compiler-rt/make/platform/clang_linux_embedded_test_input.c
-new file mode 100644
-index 000000000000..e69de29bb2d1
diff --git a/meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch b/meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
similarity index 96%
rename from meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
rename to meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
index 3c7c274693..583718c6ee 100644
--- a/meta/recipes-devtools/clang/clang/0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
+++ b/meta/recipes-devtools/clang/clang/0002-llvm-allow-env-override-of-exe-and-libdir-path.patch
@@ -1,4 +1,4 @@
-From d13464858866ff3c0026294d6842f74a11a0d625 Mon Sep 17 00:00:00 2001
+From 9aa64eaa942dad120bc6baaf17d6d859049f9de9 Mon Sep 17 00:00:00 2001
 From: Martin Kelly <mkelly@xevo.com<mailto:mkelly@xevo.com>>
 Date: Fri, 19 May 2017 00:22:57 -0700
 Subject: [PATCH] llvm: allow env override of exe and libdir path
@@ -19,7 +19,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 19 insertions(+), 6 deletions(-)

 diff --git a/llvm/tools/llvm-config/llvm-config.cpp b/llvm/tools/llvm-config/llvm-config.cpp
-index 24ea264419af..0a3f51ae2b83 100644
+index 76aa9f8..64795e9 100644
 --- a/llvm/tools/llvm-config/llvm-config.cpp
 +++ b/llvm/tools/llvm-config/llvm-config.cpp
 @@ -248,6 +248,13 @@ Typical components:\n\
diff --git a/meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch b/meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
similarity index 87%
rename from meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch
rename to meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
index e4636d30d1..d68dc94b03 100644
--- a/meta/recipes-devtools/clang/clang/0005-clang-driver-Check-sysroot-for-ldso-path.patch
+++ b/meta/recipes-devtools/clang/clang/0003-clang-driver-Check-sysroot-for-ldso-path.patch
@@ -1,4 +1,4 @@
-From 7a12ad3232dd6881ca40d94277ca8064a12d9df6 Mon Sep 17 00:00:00 2001
+From 6d26dbc005701acc1dbbd9e05e8596328a7d58f1 Mon Sep 17 00:00:00 2001
 From: Dan McGregor <dan.mcgregor@usask.ca<mailto:dan.mcgregor@usask.ca>>
 Date: Wed, 26 Apr 2017 20:29:41 -0600
 Subject: [PATCH] clang: driver: Check sysroot for ldso path
@@ -17,10 +17,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 21 insertions(+), 1 deletion(-)

 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index d525b417b4ea..1c31901ade74 100644
+index 8d30a5e..1958c64 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -630,8 +630,12 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -645,8 +645,12 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
          Triple.getEnvironment() == llvm::Triple::GNUEABIHFT64 ||
          tools::arm::getARMFloatABI(*this, Args) == tools::arm::FloatABI::Hard;

@@ -34,7 +34,7 @@ index d525b417b4ea..1c31901ade74 100644
      break;
    }
    case llvm::Triple::loongarch32: {
-@@ -685,11 +689,19 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -700,11 +704,19 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
      LibDir = "lib64";
      Loader =
          (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
@@ -53,8 +53,8 @@ index d525b417b4ea..1c31901ade74 100644
 +    }
      break;
    case llvm::Triple::riscv32:
-   case llvm::Triple::riscv64: {
-@@ -707,6 +719,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+   case llvm::Triple::riscv64:
+@@ -724,6 +736,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
    case llvm::Triple::sparcv9:
      LibDir = "lib64";
      Loader = "ld-linux.so.2";
@@ -65,7 +65,7 @@ index d525b417b4ea..1c31901ade74 100644
      break;
    case llvm::Triple::systemz:
      LibDir = "lib";
-@@ -721,6 +737,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -738,6 +754,10 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {

      LibDir = X32 ? "libx32" : "lib64";
      Loader = X32 ? "ld-linux-x32.so.2" : "ld-linux-x86-64.so.2";
diff --git a/meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch b/meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
rename to meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
index 0269dece67..1ba19bb4cd 100644
--- a/meta/recipes-devtools/clang/clang/0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
+++ b/meta/recipes-devtools/clang/clang/0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
@@ -1,4 +1,4 @@
-From 19b8ca2e1aa536e7d7f7eb379fc4e4d6f1efd07a Mon Sep 17 00:00:00 2001
+From 64a5c3e2680fb2a04ecba015af8eb5049c4840e1 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Thu, 19 May 2016 21:11:06 -0700
 Subject: [PATCH] clang: Driver/tools.cpp: Add -lssp_nonshared on musl
@@ -14,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 6 insertions(+)

 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index cb6a9b242421..8f126474b7d1 100644
+index 24076d8..a7a64fc 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -539,6 +539,12 @@ void tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
+@@ -537,6 +537,12 @@ void tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
        if (IsIAMCU)
          CmdArgs.push_back("-lgloss");

diff --git a/meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch b/meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
similarity index 81%
rename from meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch
rename to meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
index 321de79c78..0de2208a0f 100644
--- a/meta/recipes-devtools/clang/clang/0007-clang-Prepend-trailing-to-sysroot.patch
+++ b/meta/recipes-devtools/clang/clang/0005-clang-Prepend-trailing-to-sysroot.patch
@@ -1,4 +1,4 @@
-From 1746960b385afbc9e8e355a3b7c66b43c946451b Mon Sep 17 00:00:00 2001
+From e6285791435950771c13b442319efdcd6a21d81e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Thu, 16 Mar 2017 09:02:13 -0700
 Subject: [PATCH] clang: Prepend trailing '/' to sysroot
@@ -25,12 +25,12 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 1 insertion(+), 1 deletion(-)

 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 1c31901ade74..f7f096c1ac0a 100644
+index 1958c64..cb2b227 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -235,7 +235,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
-   Multilibs = GCCInstallation.getMultilibs();
-   SelectedMultilibs.assign({GCCInstallation.getMultilib()});
+@@ -238,7 +238,7 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+   loadMultilibsFromYAML(Args, D);
+
    llvm::Triple::ArchType Arch = Triple.getArch();
 -  std::string SysRoot = computeSysRoot();
 +  std::string SysRoot = computeSysRoot() + "/";
diff --git a/meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch b/meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
similarity index 94%
rename from meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch
rename to meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
index 38470e9834..427842a07a 100644
--- a/meta/recipes-devtools/clang/clang/0009-clang-Define-releative-gcc-installation-dir.patch
+++ b/meta/recipes-devtools/clang/clang/0006-clang-Define-releative-gcc-installation-dir.patch
@@ -1,4 +1,4 @@
-From bfba4232621e151cfc5dcb16ce5bf661f8c3d8f8 Mon Sep 17 00:00:00 2001
+From 04e0958fea64ebc9c89c0a6c147e8806a87727bd Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Sat, 20 Mar 2021 16:09:16 -0700
 Subject: [PATCH] clang: Define / releative gcc installation dir
@@ -61,7 +61,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 14 insertions(+), 8 deletions(-)

 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index 8f126474b7d1..c80980a7fb09 100644
+index a7a64fc..f44663f 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
 @@ -18,6 +18,7 @@
@@ -72,7 +72,7 @@ index 8f126474b7d1..c80980a7fb09 100644
  #include "clang/Driver/Driver.h"
  #include "clang/Driver/MultilibBuilder.h"
  #include "clang/Driver/Tool.h"
-@@ -2847,6 +2848,7 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
+@@ -2869,6 +2870,7 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
      const llvm::Triple &TargetTriple, const ArgList &Args,
      const std::string &LibDir, StringRef CandidateTriple,
      bool NeedsBiarchSuffix, bool GCCDirExists, bool GCCCrossDirExists) {
@@ -80,7 +80,7 @@ index 8f126474b7d1..c80980a7fb09 100644
    // Locations relative to the system lib directory where GCC's triple-specific
    // directories might reside.
    struct GCCLibSuffix {
-@@ -2858,19 +2860,20 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
+@@ -2880,19 +2882,20 @@ void Generic_GCC::GCCInstallationDetector::ScanLibDirForGCCTriple(
      // Whether this library suffix is relevant for the triple.
      bool Active;
    } Suffixes[] = {
@@ -108,7 +108,7 @@ index 8f126474b7d1..c80980a7fb09 100644

    SmallVector<GCCInstallCandidate, 3> Installations;
    for (auto &Suffix : Suffixes) {
-@@ -3273,8 +3276,11 @@ Generic_GCC::addLibCxxIncludePaths(const llvm::opt::ArgList &DriverArgs,
+@@ -3297,8 +3300,11 @@ Generic_GCC::addLibCxxIncludePaths(const llvm::opt::ArgList &DriverArgs,
    // incompatible with the NDK libraries.
    SmallString<128> DriverIncludeDir(getDriver().Dir);
    llvm::sys::path::append(DriverIncludeDir, "..", "include");
diff --git a/meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch b/meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
rename to meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
index b338d0f570..e07f004fb4 100644
--- a/meta/recipes-devtools/clang/clang/0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
+++ b/meta/recipes-devtools/clang/clang/0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
@@ -1,8 +1,8 @@
-From 03875620d0172a7c07e3cdc607a6877b06a130e9 Mon Sep 17 00:00:00 2001
+From f64b2adab7e4c515aa1e082054ad4514898e2d5d Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Wed, 31 Jul 2019 22:51:39 -0700
-Subject: [PATCH] clang: Add -lpthread and -ldl along with -lunwind for static
- linking
+Subject: [PATCH] clang: Add -lpthread and -ldl along with -lunwind for
+ static linking

 When doing static liking with --unwindlib=libunwind -static we encounter
 undefined symbols
@@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 2 insertions(+)

 diff --git a/clang/lib/Driver/ToolChains/CommonArgs.cpp b/clang/lib/Driver/ToolChains/CommonArgs.cpp
-index 10a1a412eea0..a217897610c3 100644
+index 08c0695..362e7ca 100644
 --- a/clang/lib/Driver/ToolChains/CommonArgs.cpp
 +++ b/clang/lib/Driver/ToolChains/CommonArgs.cpp
-@@ -2415,6 +2415,8 @@ static void AddUnwindLibrary(const ToolChain &TC, const Driver &D,
+@@ -2484,6 +2484,8 @@ static void AddUnwindLibrary(const ToolChain &TC, const Driver &D,
          CmdArgs.push_back("-lunwind");
      } else if (LGT == LibGccType::StaticLibGcc) {
        CmdArgs.push_back("-l:libunwind.a");
diff --git a/meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch b/meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch
rename to meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
index ba6a5c1510..c9764c70e9 100644
--- a/meta/recipes-devtools/clang/clang/0011-Check-for-atomic-double-intrinsics.patch
+++ b/meta/recipes-devtools/clang/clang/0008-Check-for-atomic-double-intrinsics.patch
@@ -1,4 +1,4 @@
-From ea4326b11976e48dde6d99605ac24df048cd3b10 Mon Sep 17 00:00:00 2001
+From a4a94de113dce4cf88c05bf0d5628a902ed93ff3 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Mon, 18 Nov 2019 17:00:29 -0800
 Subject: [PATCH] Check for atomic<double> intrinsics
@@ -16,7 +16,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 2 insertions(+), 1 deletion(-)

 diff --git a/llvm/cmake/modules/CheckAtomic.cmake b/llvm/cmake/modules/CheckAtomic.cmake
-index f11cadf39ff6..80a18a92956a 100644
+index f11cadf..80a18a9 100644
 --- a/llvm/cmake/modules/CheckAtomic.cmake
 +++ b/llvm/cmake/modules/CheckAtomic.cmake
 @@ -30,10 +30,11 @@ function(check_working_cxx_atomics64 varname)
diff --git a/meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch b/meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
similarity index 89%
rename from meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch
rename to meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
index 946eb1661f..2a3744f225 100644
--- a/meta/recipes-devtools/clang/clang/0012-cmake-Fix-configure-for-packages-using-find_package.patch
+++ b/meta/recipes-devtools/clang/clang/0009-cmake-Fix-configure-for-packages-using-find_package.patch
@@ -1,4 +1,4 @@
-From dc281691e778a61cc14bca4eb187792d2ffb384c Mon Sep 17 00:00:00 2001
+From d373417d4724071c98f95d17c88cc78e9dc1c241 Mon Sep 17 00:00:00 2001
 From: Ovidiu Panait <ovidiu.panait@windriver.com<mailto:ovidiu.panait@windriver.com>>
 Date: Fri, 31 Jan 2020 10:56:11 +0200
 Subject: [PATCH] cmake: Fix configure for packages using find_package()
@@ -31,7 +31,7 @@ Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com<mailto:ovidiu.panait@windriver.com>>
  3 files changed, 2 insertions(+), 15 deletions(-)

 diff --git a/clang/cmake/modules/AddClang.cmake b/clang/cmake/modules/AddClang.cmake
-index 4059fc3e986c..44d43aa8f25b 100644
+index e2112d7..f51983d 100644
 --- a/clang/cmake/modules/AddClang.cmake
 +++ b/clang/cmake/modules/AddClang.cmake
 @@ -182,7 +182,6 @@ macro(add_clang_tool name)
@@ -51,10 +51,10 @@ index 4059fc3e986c..44d43aa8f25b 100644
    endif()
    set_target_properties(${name} PROPERTIES XCODE_GENERATE_SCHEME ON)
 diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake
-index d938214f9d0d..4816f2127e14 100644
+index a267166..09ff2af 100644
 --- a/llvm/cmake/modules/AddLLVM.cmake
 +++ b/llvm/cmake/modules/AddLLVM.cmake
-@@ -1485,7 +1485,6 @@ macro(llvm_add_tool project name)
+@@ -1625,7 +1625,6 @@ macro(llvm_add_tool project name)
        if( LLVM_BUILD_TOOLS )
          get_target_export_arg(${name} ${project} export_to_llvmexports)
          install(TARGETS ${name}
@@ -62,7 +62,7 @@ index d938214f9d0d..4816f2127e14 100644
                  RUNTIME DESTINATION ${${project}_TOOLS_INSTALL_DIR}
                  COMPONENT ${name})
          if (LLVM_ENABLE_PDB)
-@@ -1501,10 +1500,8 @@ macro(llvm_add_tool project name)
+@@ -1641,10 +1640,8 @@ macro(llvm_add_tool project name)
          endif()
        endif()
      endif()
@@ -75,7 +75,7 @@ index d938214f9d0d..4816f2127e14 100644
    endif()
    get_subproject_title(subproject_title)
    set_target_properties(${name} PROPERTIES FOLDER "${subproject_title}/Tools")
-@@ -1559,7 +1556,6 @@ macro(add_llvm_utility name)
+@@ -1699,7 +1696,6 @@ macro(add_llvm_utility name)
      if (LLVM_INSTALL_UTILS AND LLVM_BUILD_UTILS)
        get_target_export_arg(${name} LLVM export_to_llvmexports)
        install(TARGETS ${name}
@@ -83,7 +83,7 @@ index d938214f9d0d..4816f2127e14 100644
                RUNTIME DESTINATION ${LLVM_UTILS_INSTALL_DIR}
                COMPONENT ${name})
        if (LLVM_ENABLE_PDB)
-@@ -1573,7 +1569,6 @@ macro(add_llvm_utility name)
+@@ -1713,7 +1709,6 @@ macro(add_llvm_utility name)
                                   DEPENDS ${name}
                                   COMPONENT ${name})
        endif()
@@ -92,10 +92,10 @@ index d938214f9d0d..4816f2127e14 100644
        set_property(GLOBAL APPEND PROPERTY LLVM_EXPORTS_BUILDTREE_ONLY ${name})
      endif()
 diff --git a/llvm/cmake/modules/TableGen.cmake b/llvm/cmake/modules/TableGen.cmake
-index 84c03cd6432e..72da60ce3ca1 100644
+index 397089a..5240962 100644
 --- a/llvm/cmake/modules/TableGen.cmake
 +++ b/llvm/cmake/modules/TableGen.cmake
-@@ -237,12 +237,7 @@ macro(add_tablegen target project)
+@@ -239,12 +239,7 @@ macro(add_tablegen target project)

    if (ADD_TABLEGEN_DESTINATION AND NOT LLVM_INSTALL_TOOLCHAIN_ONLY AND
        (LLVM_BUILD_UTILS OR ${target} IN_LIST LLVM_DISTRIBUTION_COMPONENTS))
@@ -108,7 +108,7 @@ index 84c03cd6432e..72da60ce3ca1 100644
              COMPONENT ${target}
              RUNTIME DESTINATION "${ADD_TABLEGEN_DESTINATION}")
      if(NOT LLVM_ENABLE_IDE)
-@@ -253,7 +248,6 @@ macro(add_tablegen target project)
+@@ -255,7 +250,6 @@ macro(add_tablegen target project)
    endif()
    if(ADD_TABLEGEN_EXPORT)
      string(TOUPPER ${ADD_TABLEGEN_EXPORT} export_upper)
diff --git a/meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch b/meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
similarity index 95%
rename from meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
rename to meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
index 72b989c0a2..df6c44bca1 100644
--- a/meta/recipes-devtools/clang/clang/0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
+++ b/meta/recipes-devtools/clang/clang/0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch
@@ -1,4 +1,4 @@
-From 248a51bece02c199d0f84d14fa7e2e2379c592a0 Mon Sep 17 00:00:00 2001
+From d03df63cfd772452b5b7c8ddb587f576f054b004 Mon Sep 17 00:00:00 2001
 From: Jim Broadus <jbroadus@xevo.com<mailto:jbroadus@xevo.com>>
 Date: Thu, 26 Mar 2020 16:05:53 -0700
 Subject: [PATCH] clang: Fix resource dir location for cross toolchains
@@ -21,7 +21,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 8 insertions(+), 1 deletion(-)

 diff --git a/clang/lib/Options/OptionUtils.cpp b/clang/lib/Options/OptionUtils.cpp
-index e5aefa012f67..7c1b657ce2c1 100644
+index 77f8955..62bb694 100644
 --- a/clang/lib/Options/OptionUtils.cpp
 +++ b/clang/lib/Options/OptionUtils.cpp
 @@ -213,6 +213,7 @@ std::string clang::GetResourcesPath(StringRef BinaryPath) {
diff --git a/meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch b/meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
similarity index 88%
rename from meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
rename to meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
index 725d10a2a7..29d7a6d6bc 100644
--- a/meta/recipes-devtools/clang/clang/0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
+++ b/meta/recipes-devtools/clang/clang/0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
@@ -1,8 +1,8 @@
-From b3eea8bcdb792a7b19b879c76eac64f36d1fe012 Mon Sep 17 00:00:00 2001
+From 75e6420bd7f45f1b60a856d51866e22d83cf55b0 Mon Sep 17 00:00:00 2001
 From: Oleksandr Ocheretnyi <oocheret@cisco.com<mailto:oocheret@cisco.com>>
 Date: Wed, 15 Apr 2020 00:08:39 +0300
-Subject: [PATCH] clang: driver: Add dyld-prefix when checking sysroot for ldso
- path
+Subject: [PATCH] clang: driver: Add dyld-prefix when checking sysroot
+ for ldso path

  * the dyld-prefix shall be taken into account when the default
    path for the dynamic linker has to be checked.
@@ -19,10 +19,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 10 insertions(+), 10 deletions(-)

 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index f7f096c1ac0a..7b608a84a66e 100644
+index cb2b227..c2ac9b6 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -632,8 +632,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -647,8 +647,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {

      Loader = HF ? "ld-linux-armhf.so.3" : "ld-linux.so.3";
      LibDir = "lib32";
@@ -33,7 +33,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -689,8 +689,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -704,8 +704,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
      LibDir = "lib64";
      Loader =
          (tools::ppc::hasPPCAbiArg(Args, "elfv2")) ? "ld64.so.2" : "ld64.so.1";
@@ -44,7 +44,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -698,8 +698,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -713,8 +713,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
      LibDir = "lib64";
      Loader =
          (tools::ppc::hasPPCAbiArg(Args, "elfv1")) ? "ld64.so.1" : "ld64.so.2";
@@ -55,7 +55,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -719,8 +719,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -736,8 +736,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
    case llvm::Triple::sparcv9:
      LibDir = "lib64";
      Loader = "ld-linux.so.2";
@@ -66,7 +66,7 @@ index f7f096c1ac0a..7b608a84a66e 100644
          LibDir = "lib";
      }
      break;
-@@ -737,8 +737,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {
+@@ -754,8 +754,8 @@ std::string Linux::getDynamicLinker(const ArgList &Args) const {

      LibDir = X32 ? "libx32" : "lib64";
      Loader = X32 ? "ld-linux-x32.so.2" : "ld-linux-x86-64.so.2";
diff --git a/meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch b/meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
similarity index 90%
rename from meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch
rename to meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
index e29d23cab2..5b0a0b3431 100644
--- a/meta/recipes-devtools/clang/clang/0015-clang-Use-python3-in-python-scripts.patch
+++ b/meta/recipes-devtools/clang/clang/0012-clang-Use-python3-in-python-scripts.patch
@@ -1,4 +1,4 @@
-From 17e1af5e12a01296d2c032a768569d4d8b06505b Mon Sep 17 00:00:00 2001
+From bc161f33adb168a0a1614d38eb84190c3f690000 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Wed, 14 Oct 2020 22:19:57 -0700
 Subject: [PATCH] clang: Use python3 in python scripts
@@ -14,7 +14,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  2 files changed, 2 insertions(+), 2 deletions(-)

 diff --git a/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py b/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
-index 49a1b1493264..6158876d15f7 100755
+index 49a1b14..6158876 100755
 --- a/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
 +++ b/clang-tools-extra/clang-include-fixer/find-all-symbols/tool/run-find-all-symbols.py
 @@ -1,4 +1,4 @@
@@ -24,7 +24,7 @@ index 49a1b1493264..6158876d15f7 100755
  # =- run-find-all-symbols.py - Parallel find-all-symbols runner -*- python  -*-=#
  #
 diff --git a/clang/tools/scan-view/bin/scan-view b/clang/tools/scan-view/bin/scan-view
-index d01aebb4029a..f3375804654d 100755
+index d01aebb..f337580 100755
 --- a/clang/tools/scan-view/bin/scan-view
 +++ b/clang/tools/scan-view/bin/scan-view
 @@ -1,4 +1,4 @@
diff --git a/meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch b/meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
rename to meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
index 674a3b264e..aba7488323 100644
--- a/meta/recipes-devtools/clang/clang/0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
+++ b/meta/recipes-devtools/clang/clang/0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
@@ -1,7 +1,8 @@
-From 259d8eb2ed82c9248387a3cbb1befee358ecbb8e Mon Sep 17 00:00:00 2001
+From 12fbb32963d7aad6c0d5a0ca5fc0f536f1a9b4fe Mon Sep 17 00:00:00 2001
 From: Hongxu Jia <hongxu.jia@windriver.com<mailto:hongxu.jia@windriver.com>>
 Date: Mon, 25 Jan 2021 16:14:35 +0800
-Subject: [PATCH] llvm/clang: Insert anchor for adding OE distro vendor names
+Subject: [PATCH] llvm/clang: Insert anchor for adding OE distro vendor
+ names
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
@@ -99,11 +100,11 @@ Signed-off-by: João Marcos Costa <joaomarcos.costa@bootlin.com<mailto:joaomarcos.costa@bootlin.com>>
  clang/lib/Driver/Distro.cpp           | 1 +
  clang/lib/Driver/ToolChains/Gnu.cpp   | 1 +
  clang/lib/Driver/ToolChains/Linux.cpp | 2 ++
- llvm/lib/TargetParser/Triple.cpp      | 2 +-
- 5 files changed, 7 insertions(+), 1 deletion(-)
+ llvm/lib/TargetParser/Triple.cpp      | 1 +
+ 5 files changed, 7 insertions(+)

 diff --git a/clang/include/clang/Driver/Distro.h b/clang/include/clang/Driver/Distro.h
-index 0e17b30eb..b449a62dc 100644
+index aa4b3e1..2d77a2b 100644
 --- a/clang/include/clang/Driver/Distro.h
 +++ b/clang/include/clang/Driver/Distro.h
 @@ -45,6 +45,7 @@ public:
@@ -114,7 +115,7 @@ index 0e17b30eb..b449a62dc 100644
      OpenSUSE,
      UbuntuQuantal,
      UbuntuRaring,
-@@ -132,6 +133,7 @@ public:
+@@ -133,6 +134,7 @@ public:

    bool IsGentoo() const { return DistroVal == Gentoo; }

@@ -123,7 +124,7 @@ index 0e17b30eb..b449a62dc 100644
  };

 diff --git a/clang/lib/Driver/Distro.cpp b/clang/lib/Driver/Distro.cpp
-index df10458d0..61dc127a4 100644
+index 585497e..3b58ac7 100644
 --- a/clang/lib/Driver/Distro.cpp
 +++ b/clang/lib/Driver/Distro.cpp
 @@ -43,6 +43,7 @@ static Distro::DistroType DetectOsRelease(llvm::vfs::FileSystem &VFS) {
@@ -135,10 +136,10 @@ index df10458d0..61dc127a4 100644
    return Version;
  }
 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index c80980a7f..80fd8058b 100644
+index f44663f..73ff1f4 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2370,6 +2370,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
+@@ -2371,6 +2371,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
        "x86_64-pc-linux-gnu",    "x86_64-redhat-linux6E",
        "x86_64-redhat-linux",    "x86_64-suse-linux",
        "x86_64-manbo-linux-gnu", "x86_64-slackware-linux",
@@ -147,7 +148,7 @@ index c80980a7f..80fd8058b 100644
    static const char *const X32Triples[] = {"x86_64-linux-gnux32",
                                             "x86_64-pc-linux-gnux32"};
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 7b608a84a..585a86a2d 100644
+index c2ac9b6..3231f36 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
 @@ -45,6 +45,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
@@ -167,18 +168,14 @@ index 7b608a84a..585a86a2d 100644
    case llvm::Triple::aarch64:
      if (IsAndroid)
 diff --git a/llvm/lib/TargetParser/Triple.cpp b/llvm/lib/TargetParser/Triple.cpp
-index a4f9dd42c..86b74451e 100644
+index 356782c..883e654 100644
 --- a/llvm/lib/TargetParser/Triple.cpp
 +++ b/llvm/lib/TargetParser/Triple.cpp
-@@ -702,7 +702,7 @@ static Triple::VendorType parseVendor(StringRef VendorName) {
-       .Case("suse", Triple::SUSE)
-       .Case("oe", Triple::OpenEmbedded)
-       .Case("intel", Triple::Intel)
--      .Case("meta", Triple::Meta)
-+      .Case("meta", Triple::Meta) //CLANG_EXTRA_OE_VENDORS_CASES
+@@ -741,6 +741,7 @@ static Triple::VendorType parseVendor(StringRef VendorName) {
+ #define TRIPLE_VENDOR(Enum, Name) .Case(Name, Triple::Enum)
+ #define TRIPLE_VENDOR_ALIAS(Enum, AliasName) .Case(AliasName, Triple::Enum)
+ #include "llvm/TargetParser/TripleName.def"
++      //CLANG_EXTRA_OE_VENDORS_CASES
        .Default(Triple::UnknownVendor);
  }

---
-2.39.5
-
diff --git a/meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch b/meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
rename to meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
index 786ff426d3..d54859c338 100644
--- a/meta/recipes-devtools/clang/clang/0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
+++ b/meta/recipes-devtools/clang/clang/0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
@@ -1,7 +1,8 @@
-From 6839ba1413cf09eb14a24eeda44fb02c1c6809e1 Mon Sep 17 00:00:00 2001
+From 0a569622e3ebdb2ebd1a2a4f9553161c1bd188d8 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Wed, 19 May 2021 17:56:03 -0700
-Subject: [PATCH] clang: Fix x86 triple for non-debian multiarch linux distros
+Subject: [PATCH] clang: Fix x86 triple for non-debian multiarch linux
+ distros

 OpenEmbedded does not hardcode mutli-arch like debian therefore ensure
 that it still uses the proper tuple
@@ -13,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 2 insertions(+), 1 deletion(-)

 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 4a0adedce09a..9fed904c05c2 100644
+index 3231f36..41e0017 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -227,8 +227,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
+@@ -228,8 +228,9 @@ Linux::Linux(const Driver &D, const llvm::Triple &Triple, const ArgList &Args)
      : Generic_ELF(D, Triple, Args) {
    GCCInstallation.TripleToDebianMultiarch = [](const llvm::Triple &T) {
      StringRef TripleStr = T.str();
diff --git a/meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch b/meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
similarity index 89%
rename from meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch
rename to meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
index 0b7966ee57..2beff16173 100644
--- a/meta/recipes-devtools/clang/clang/0019-libunwind-Added-unw_backtrace-method.patch
+++ b/meta/recipes-devtools/clang/clang/0015-libunwind-Added-unw_backtrace-method.patch
@@ -1,4 +1,4 @@
-From bf7c0933d65eb811c993ff32fdc6b65f6befc5af Mon Sep 17 00:00:00 2001
+From 1ab2bd0edf76583f0e430da5ef8a53ca4029455f Mon Sep 17 00:00:00 2001
 From: Maksim Kita <maksim-kita@yandex-team.ru<mailto:maksim-kita@yandex-team.ru>>
 Date: Sun, 23 May 2021 10:27:29 +0000
 Subject: [PATCH] libunwind: Added unw_backtrace method
@@ -12,7 +12,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  2 files changed, 21 insertions(+)

 diff --git a/libunwind/include/libunwind.h b/libunwind/include/libunwind.h
-index 56ca7110274a..60a27f28100b 100644
+index 6c2dfe5..602cafb 100644
 --- a/libunwind/include/libunwind.h
 +++ b/libunwind/include/libunwind.h
 @@ -235,6 +235,7 @@ extern int unw_is_signal_frame(unw_cursor_t *) LIBUNWIND_AVAIL;
@@ -24,10 +24,10 @@ index 56ca7110274a..60a27f28100b 100644
  extern unw_addr_space_t unw_local_addr_space;

 diff --git a/libunwind/src/libunwind.cpp b/libunwind/src/libunwind.cpp
-index 7ffffc2a30c0..ed0b394cb002 100644
+index 0b9d56e..fbfbd48 100644
 --- a/libunwind/src/libunwind.cpp
 +++ b/libunwind/src/libunwind.cpp
-@@ -531,6 +531,26 @@ int __unw_remove_find_dynamic_unwind_sections(
+@@ -527,6 +527,26 @@ int __unw_remove_find_dynamic_unwind_sections(

  #endif // __APPLE__

diff --git a/meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch b/meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
similarity index 92%
rename from meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch
rename to meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
index b9f7270f62..45a71fc2ab 100644
--- a/meta/recipes-devtools/clang/clang/0020-lldb-Link-with-libatomic-on-x86.patch
+++ b/meta/recipes-devtools/clang/clang/0016-lldb-Link-with-libatomic-on-x86.patch
@@ -1,4 +1,4 @@
-From 94c6e940ddc44922ee505993549477a0fa7ac50d Mon Sep 17 00:00:00 2001
+From 765a550228a57f9bf88ea2c284a5aec01c4c220e Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Tue, 8 Feb 2022 01:31:26 -0800
 Subject: [PATCH] lldb: Link with libatomic on x86
@@ -17,7 +17,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 4 insertions(+)

 diff --git a/lldb/source/Utility/CMakeLists.txt b/lldb/source/Utility/CMakeLists.txt
-index 04f1692e53b3..da0a48d9da54 100644
+index c0d0a42..463c0d7 100644
 --- a/lldb/source/Utility/CMakeLists.txt
 +++ b/lldb/source/Utility/CMakeLists.txt
 @@ -19,6 +19,10 @@ if (CMAKE_SYSTEM_NAME MATCHES "Windows")
diff --git a/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
deleted file mode 100644
index 3fa436d526..0000000000
--- a/meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From bc8371eb77cca413ccb4ebf8239c597f7be40006 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
-Date: Wed, 19 May 2021 17:32:13 -0700
-Subject: [PATCH] compiler-rt: Do not use backtrace APIs on non-glibc linux
-
-musl e.g. does not provide backtrace APIs
-
-Upstream-Status: Pending
-Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
----
- .../lib/gwp_asan/optional/backtrace_linux_libc.cpp  | 13 ++++++++++++-
- 1 file changed, 12 insertions(+), 1 deletion(-)
-
-diff --git a/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp b/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
-index ea8e72be287d..0344074dd254 100644
---- a/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
-+++ b/compiler-rt/lib/gwp_asan/optional/backtrace_linux_libc.cpp
-@@ -7,7 +7,9 @@
- //===----------------------------------------------------------------------===//
-
- #include <assert.h>
-+#ifdef __GLIBC__
- #include <execinfo.h>
-+#endif
- #include <stddef.h>
- #include <stdint.h>
- #include <stdlib.h>
-@@ -21,8 +23,11 @@
- namespace {
- size_t Backtrace(uintptr_t *TraceBuffer, size_t Size) {
-   static_assert(sizeof(uintptr_t) == sizeof(void *), "uintptr_t is not void*");
--
-+#ifdef __GLIBC__
-   return backtrace(reinterpret_cast<void **>(TraceBuffer), Size);
-+#else
-+  return -1;
-+#endif
- }
-
- // We don't need any custom handling for the Segv backtrace - the libc unwinder
-@@ -30,7 +35,11 @@ size_t Backtrace(uintptr_t *TraceBuffer, size_t Size) {
- // to avoid the additional frame.
- GWP_ASAN_ALWAYS_INLINE size_t SegvBacktrace(uintptr_t *TraceBuffer, size_t Size,
-                                             void * /*Context*/) {
-+#ifdef __GLIBC__
-   return Backtrace(TraceBuffer, Size);
-+#else
-+  return -1;
-+#endif
- }
-
- static void PrintBacktrace(uintptr_t *Trace, size_t TraceLength,
-@@ -40,6 +49,7 @@ static void PrintBacktrace(uintptr_t *Trace, size_t TraceLength,
-     return;
-   }
-
-+#ifdef __GLIBC__
-   char **BacktraceSymbols =
-       backtrace_symbols(reinterpret_cast<void **>(Trace), TraceLength);
-
-@@ -53,6 +63,7 @@ static void PrintBacktrace(uintptr_t *Trace, size_t TraceLength,
-   Printf("\n");
-   if (BacktraceSymbols)
-     free(BacktraceSymbols);
-+#endif
- }
- } // anonymous namespace
-
diff --git a/meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
similarity index 77%
rename from meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch
rename to meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
index 89b492b877..12749e8f96 100644
--- a/meta/recipes-devtools/clang/clang/0021-compiler-rt-Enable-__int128-for-ppc32.patch
+++ b/meta/recipes-devtools/clang/clang/0017-compiler-rt-Enable-__int128-for-ppc32.patch
@@ -1,4 +1,4 @@
-From 968515d7aa2d7e4af5f318618c307dbe21538650 Mon Sep 17 00:00:00 2001
+From 3a7b96edc836c0264206f01f5fc7e0cd1bc6c70c Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Wed, 9 Mar 2022 16:28:16 -0800
 Subject: [PATCH] compiler-rt: Enable __int128 for ppc32
@@ -6,15 +6,15 @@ Subject: [PATCH] compiler-rt: Enable __int128 for ppc32
 Upstream-Status: Pending
 Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 ---
- compiler-rt/lib/builtins/CMakeLists.txt | 13 ++++++-------
+ compiler-rt/lib/builtins/CMakeLists.txt | 17 ++++++-----------
  compiler-rt/lib/builtins/int_types.h    |  2 +-
- 2 files changed, 7 insertions(+), 8 deletions(-)
+ 2 files changed, 7 insertions(+), 12 deletions(-)

 diff --git a/compiler-rt/lib/builtins/CMakeLists.txt b/compiler-rt/lib/builtins/CMakeLists.txt
-index c3dbd65998f1..b3a44ea3c3b3 100644
+index e128fea..eb108d7 100644
 --- a/compiler-rt/lib/builtins/CMakeLists.txt
 +++ b/compiler-rt/lib/builtins/CMakeLists.txt
-@@ -813,11 +813,9 @@ set(mips64el_SOURCES ${GENERIC_TF_SOURCES}
+@@ -916,11 +916,9 @@ set(mips64el_SOURCES ${GENERIC_TF_SOURCES}

  set(nvptx64_SOURCES ${GENERIC_SOURCES})

@@ -27,7 +27,7 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
    ppc/divtc3.c
    ppc/fixtfdi.c
    ppc/fixunstfdi.c
-@@ -832,14 +830,15 @@ set(powerpc64_SOURCES
+@@ -935,11 +933,11 @@ set(powerpc64_SOURCES
  )
  # These routines require __int128, which isn't supported on AIX.
  if (NOT OS_NAME MATCHES "AIX")
@@ -40,13 +40,23 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
 +    ${powerpc_SOURCES}
    )
  endif()
+ if (OS_NAME MATCHES "AIX")
+@@ -947,12 +945,9 @@ if (OS_NAME MATCHES "AIX")
+     ppc/init_ifuncs.c
+     ${powerpc_SOURCES}
+   )
+-  set(powerpc64_SOURCES
+-    ppc/init_ifuncs.c
+-    ${powerpc64_SOURCES}
+-  )
+ endif()
 -set(powerpc64le_SOURCES ${powerpc64_SOURCES})
 +set(powerpc64le_SOURCES ${powerpc_SOURCES})
 +set(powerpc64_SOURCES ${powerpc_SOURCES})

  set(riscv_SOURCES
    cpu_model/riscv.c
-@@ -1014,7 +1013,7 @@ else ()
+@@ -1125,7 +1120,7 @@ else ()

        # For RISCV32 and 32-bit SPARC, we must force enable int128 for compiling long
        # double routines.
@@ -56,7 +66,7 @@ index c3dbd65998f1..b3a44ea3c3b3 100644
          list(APPEND BUILTIN_CFLAGS_${arch} -fforce-enable-int128)
        endif()
 diff --git a/compiler-rt/lib/builtins/int_types.h b/compiler-rt/lib/builtins/int_types.h
-index 7c7f8cb64aa9..81386f1b99b0 100644
+index 6411507..754f8ce 100644
 --- a/compiler-rt/lib/builtins/int_types.h
 +++ b/compiler-rt/lib/builtins/int_types.h
 @@ -64,7 +64,7 @@ typedef union {
diff --git a/meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch b/meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
rename to meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
index cccb1e9885..167cd12431 100644
--- a/meta/recipes-devtools/clang/clang/0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
+++ b/meta/recipes-devtools/clang/clang/0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
@@ -1,4 +1,4 @@
-From 8c5fc285de0051107aa9b7e2e269aa2667fd16f4 Mon Sep 17 00:00:00 2001
+From f610b9f158e13a40f0e86f7a171be493f8ca64fe Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Fri, 12 Aug 2022 11:50:57 -0700
 Subject: [PATCH] llvm: Do not use cmake infra to detect libzstd
@@ -21,7 +21,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 4 insertions(+), 4 deletions(-)

 diff --git a/llvm/lib/Support/CMakeLists.txt b/llvm/lib/Support/CMakeLists.txt
-index 099b0e55579b..8c35b8a31457 100644
+index 1a3fa39..dd11f9a 100644
 --- a/llvm/lib/Support/CMakeLists.txt
 +++ b/llvm/lib/Support/CMakeLists.txt
 @@ -22,7 +22,7 @@ if (HAS_WERROR_GLOBAL_CTORS)
@@ -42,7 +42,7 @@ index 099b0e55579b..8c35b8a31457 100644
  endif()

  if( WIN32 )
-@@ -351,7 +351,7 @@ if(LLVM_ENABLE_ZLIB)
+@@ -360,7 +360,7 @@ if(LLVM_ENABLE_ZLIB)
      get_property(zlib_library TARGET ZLIB::ZLIB PROPERTY LOCATION)
    endif()
    get_library_name(${zlib_library} zlib_library)
@@ -51,7 +51,7 @@ index 099b0e55579b..8c35b8a31457 100644
  endif()

  if(LLVM_ENABLE_ZSTD)
-@@ -365,7 +365,7 @@ if(LLVM_ENABLE_ZSTD)
+@@ -374,7 +374,7 @@ if(LLVM_ENABLE_ZSTD)
    endif()
    if (zstd_target STREQUAL zstd::libzstd_shared)
      get_library_name(${zstd_library} zstd_library)
diff --git a/meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch b/meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
rename to meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
index a498c36b84..021f622894 100644
--- a/meta/recipes-devtools/clang/clang/0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
+++ b/meta/recipes-devtools/clang/clang/0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
@@ -1,4 +1,4 @@
-From 4a114f5fcd2ab8870b26ba3df4747fc066933f66 Mon Sep 17 00:00:00 2001
+From 6917a5e0eb77c0134b59c3cb942292bc5c38e87f Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Tue, 3 Jan 2023 18:44:34 -0800
 Subject: [PATCH] compiler-rt: Fix stat struct's size for O32 ABI
@@ -14,7 +14,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 13 insertions(+)

 diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
-index 05ebee49f2ab..89c4dcaf3e3d 100644
+index 73eb958..b0dcbde 100644
 --- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
 +++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
 @@ -100,6 +100,18 @@ const unsigned struct_kernel_stat64_sz = 104;
@@ -36,7 +36,7 @@ index 05ebee49f2ab..89c4dcaf3e3d 100644
  const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
                                             ? FIRST_32_SECOND_64(104, 128)
  #      if defined(_ABIN32) && _MIPS_SIM == _ABIN32
-@@ -110,6 +122,7 @@ const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
+@@ -116,6 +128,7 @@ const unsigned struct_kernel_stat_sz = SANITIZER_ANDROID
                                             : FIRST_32_SECOND_64(160, 216);
  #      endif
  const unsigned struct_kernel_stat64_sz = 104;
diff --git a/meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch b/meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
similarity index 98%
rename from meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
rename to meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
index 09224af386..19784aef10 100644
--- a/meta/recipes-devtools/clang/clang/0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
+++ b/meta/recipes-devtools/clang/clang/0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
@@ -1,4 +1,4 @@
-From 27e4b9755ddd3bec16a851cce0df48e909ae6438 Mon Sep 17 00:00:00 2001
+From 0d7e696f552b1047e89c5114551b6dc902e6f0f1 Mon Sep 17 00:00:00 2001
 From: Martin Jansa <Martin.Jansa@gmail.com<mailto:Martin.Jansa@gmail.com>>
 Date: Thu, 31 Aug 2023 18:14:47 +0200
 Subject: [PATCH] ToolChains/Gnu.cpp: ARMLibDirs search also in lib32
@@ -55,10 +55,10 @@ Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com<mailto:Martin.Jansa@gmail.com>>
  2 files changed, 2 insertions(+), 1 deletion(-)

 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index 80fd8058bd98..37cb6cfdf2da 100644
+index 73ff1f4..6a2b362 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2346,7 +2346,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
+@@ -2347,7 +2347,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
    static const char *const AArch64beLibDirs[] = {"/lib"};
    static const char *const AArch64beTriples[] = {"aarch64_be-none-linux-gnu"};

@@ -68,10 +68,10 @@ index 80fd8058bd98..37cb6cfdf2da 100644
    static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf",
                                               "armv7hl-redhat-linux-gnueabi",
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 9fed904c05c2..5bb66c9faa1f 100644
+index 41e0017..5f8b7fd 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -198,6 +198,7 @@ static StringRef getOSLibDir(const llvm::Triple &Triple, const ArgList &Args) {
+@@ -199,6 +199,7 @@ static StringRef getOSLibDir(const llvm::Triple &Triple, const ArgList &Args) {
    // reasoning about oslibdir spellings with the lib dir spellings in the
    // GCCInstallationDetector, but that is a more significant refactoring.
    if (Triple.getArch() == llvm::Triple::x86 || Triple.isPPC32() ||
diff --git a/meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch b/meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
similarity index 60%
rename from meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
rename to meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
index c93a9ec7e0..6577380978 100644
--- a/meta/recipes-devtools/clang/clang/0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
+++ b/meta/recipes-devtools/clang/clang/0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
@@ -1,4 +1,4 @@
-From 7023d17f81a472e72a5739e007b9e7148d105137 Mon Sep 17 00:00:00 2001
+From 33988376d79f9eca5f54000cdcc558c8dc3d89ba Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Sat, 3 Feb 2024 16:47:10 -0800
 Subject: [PATCH] clang/llvm: Add OE specific ABI triple for N32 ABI
@@ -8,16 +8,17 @@ Its gnun32 when using OE
 Upstream-Status: Inappropriate [OE-Specific]
 Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 ---
- clang/lib/Driver/ToolChains/Gnu.cpp   | 1 +
- clang/lib/Driver/ToolChains/Linux.cpp | 4 ++--
- llvm/lib/TargetParser/Triple.cpp      | 4 +++-
- 3 files changed, 6 insertions(+), 3 deletions(-)
+ clang/lib/Driver/ToolChains/Gnu.cpp           | 1 +
+ clang/lib/Driver/ToolChains/Linux.cpp         | 4 ++--
+ llvm/include/llvm/TargetParser/TripleName.def | 2 +-
+ llvm/lib/TargetParser/Triple.cpp              | 2 ++
+ 4 files changed, 6 insertions(+), 3 deletions(-)

 diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
-index 37cb6cfdf2da..bcd7d345c25a 100644
+index 6a2b362..05d1c44 100644
 --- a/clang/lib/Driver/ToolChains/Gnu.cpp
 +++ b/clang/lib/Driver/ToolChains/Gnu.cpp
-@@ -2415,6 +2415,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(
+@@ -2416,6 +2416,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes(

    static const char *const MIPSN32LibDirs[] = {"/lib32"};
    static const char *const MIPSN32Triples[] = {"mips64-linux-gnuabin32",
@@ -26,10 +27,10 @@ index 37cb6cfdf2da..bcd7d345c25a 100644
    static const char *const MIPSN32ELLibDirs[] = {"/lib32"};
    static const char *const MIPSN32ELTriples[] = {
 diff --git a/clang/lib/Driver/ToolChains/Linux.cpp b/clang/lib/Driver/ToolChains/Linux.cpp
-index 5bb66c9faa1f..c6d6e20dbc4d 100644
+index 5f8b7fd..ac7bd3a 100644
 --- a/clang/lib/Driver/ToolChains/Linux.cpp
 +++ b/clang/lib/Driver/ToolChains/Linux.cpp
-@@ -138,7 +138,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
+@@ -139,7 +139,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
      return IsMipsR6 ? "mipsisa32r6el-linux-gnu" : "mipsel-linux-gnu";
    case llvm::Triple::mips64: {
      std::string MT = std::string(IsMipsR6 ? "mipsisa64r6" : "mips64") +
@@ -38,7 +39,7 @@ index 5bb66c9faa1f..c6d6e20dbc4d 100644
      if (D.getVFS().exists(concat(SysRoot, "/lib", MT)))
        return MT;
      if (D.getVFS().exists(concat(SysRoot, "/lib/mips64-linux-gnu")))
-@@ -147,7 +147,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
+@@ -148,7 +148,7 @@ std::string Linux::getMultiarchTriple(const Driver &D,
    }
    case llvm::Triple::mips64el: {
      std::string MT = std::string(IsMipsR6 ? "mipsisa64r6el" : "mips64el") +
@@ -47,28 +48,32 @@ index 5bb66c9faa1f..c6d6e20dbc4d 100644
      if (D.getVFS().exists(concat(SysRoot, "/lib", MT)))
        return MT;
      if (D.getVFS().exists(concat(SysRoot, "/lib/mips64el-linux-gnu")))
+diff --git a/llvm/include/llvm/TargetParser/TripleName.def b/llvm/include/llvm/TargetParser/TripleName.def
+index bbc03b3..081d8ff 100644
+--- a/llvm/include/llvm/TargetParser/TripleName.def
++++ b/llvm/include/llvm/TargetParser/TripleName.def
+@@ -102,7 +102,7 @@ TRIPLE_OS(H2, "h2")
+
+ TRIPLE_ENV(EABIHF, "eabihf")
+ TRIPLE_ENV(EABI, "eabi")
+-TRIPLE_ENV(GNUABIN32, "gnuabin32")
++TRIPLE_ENV(GNUABIN32, "gnun32")
+ TRIPLE_ENV(GNUABI64, "gnuabi64")
+ TRIPLE_ENV(GNUEABIHFT64, "gnueabihft64")
+ TRIPLE_ENV(GNUEABIHF, "gnueabihf")
 diff --git a/llvm/lib/TargetParser/Triple.cpp b/llvm/lib/TargetParser/Triple.cpp
-index 86b74451ec0d..d94b7d44d11a 100644
+index 883e654..aa2bb35 100644
 --- a/llvm/lib/TargetParser/Triple.cpp
 +++ b/llvm/lib/TargetParser/Triple.cpp
-@@ -358,7 +358,7 @@ StringRef Triple::getEnvironmentTypeName(EnvironmentType Kind) {
-   case GNU: return "gnu";
-   case GNUT64: return "gnut64";
-   case GNUABI64: return "gnuabi64";
--  case GNUABIN32: return "gnuabin32";
-+  case GNUABIN32: return "gnun32";
-   case GNUEABI: return "gnueabi";
-   case GNUEABIT64: return "gnueabit64";
-   case GNUEABIHF: return "gnueabihf";
-@@ -762,6 +762,7 @@ static Triple::EnvironmentType parseEnvironment(StringRef EnvironmentName) {
-       .StartsWith("eabihf", Triple::EABIHF)
-       .StartsWith("eabi", Triple::EABI)
-       .StartsWith("gnuabin32", Triple::GNUABIN32)
-+      .StartsWith("gnun32", Triple::GNUABIN32)
-       .StartsWith("gnuabi64", Triple::GNUABI64)
-       .StartsWith("gnueabihft64", Triple::GNUEABIHFT64)
-       .StartsWith("gnueabihf", Triple::GNUEABIHF)
-@@ -1087,6 +1088,7 @@ Triple::Triple(std::string &&Str) : Data(std::move(Str)) {
+@@ -755,6 +755,7 @@ static Triple::OSType parseOS(StringRef OSName) {
+
+ static Triple::EnvironmentType parseEnvironment(StringRef EnvironmentName) {
+   return StringSwitch<Triple::EnvironmentType>(EnvironmentName)
++      .StartsWith("gnuabin32", Triple::GNUABIN32)
+ #define TRIPLE_ENV(Enum, Name) .StartsWith(Name, Triple::Enum)
+ #include "llvm/TargetParser/TripleName.def"
+       .Default(Triple::UnknownEnvironment);
+@@ -1106,6 +1107,7 @@ Triple::Triple(std::string &&Str) : Data(std::move(Str)) {
        Environment =
            StringSwitch<Triple::EnvironmentType>(Components[0])
                .StartsWith("mipsn32", Triple::GNUABIN32)

   .def already has an alias mechanism (TRIPLE_VENDOR_ALIAS appears in the vendor rework) — if TRIPLE_ENV_ALIAS exists too, using it for gnuabin32 would keep the compat spelling in the table itself instead of hand-editing parseEnvironment, which will rebase more cleanly next

TRIPLE_ENV_ALIAS doesn't exist yet, I checked 23.1.0 and current main. Only the OS and vendor sections have alias macros.

Since Triple.cpp is the only file that includes TripleName.def, the patch can add the macro itself the same way the other two sections
do. I tried it here, the alias line sits in the table next to gnun32 and one extra #define in parseEnvironment replaces the hand edit.
The stack applies clean and llvm builds fine with it.

Is this what you had in mind? I can fold it into v2. We could also send TRIPLE_ENV_ALIAS to llvm as a small NFC patch, then this
carries just two table lines going forward.

Thanks,
Sunil Dora

diff --git a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch b/meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
similarity index 84%
rename from meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
rename to meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
index 72ffdc6c1f..34ba534074 100644
--- a/meta/recipes-devtools/clang/clang/0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
+++ b/meta/recipes-devtools/clang/clang/0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
@@ -1,4 +1,4 @@
-From 17a1a4919c0ff554fc30bbb85a63b9d2a1164324 Mon Sep 17 00:00:00 2001
+From 9ec97845821ead65ebd8ab26b69d949e10b65338 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Tue, 14 May 2024 22:04:43 -0700
 Subject: [PATCH] llvm: Add libunwind.pc.in<http://libunwind.pc.in> and llvm-config scripts
@@ -10,15 +10,15 @@ Upstream-Status: Inappropriate [ OE-Specific ]
 Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>
 ---
- libunwind/libunwind.pc.in<http://libunwind.pc.in>          |  9 ++++++
- llvm/tools/llvm-config/llvm-config | 52 ++++++++++++++++++++++++++++++
- 2 files changed, 61 insertions(+)
+ libunwind/libunwind.pc.in<http://libunwind.pc.in>          |  9 +++++++++
+ llvm/tools/llvm-config/llvm-config | 15 +++++++++++++++
+ 2 files changed, 24 insertions(+)
  create mode 100644 libunwind/libunwind.pc.in<http://libunwind.pc.in>
  create mode 100644 llvm/tools/llvm-config/llvm-config

 diff --git a/libunwind/libunwind.pc.in<http://libunwind.pc.in> b/libunwind/libunwind.pc.in<http://libunwind.pc.in>
 new file mode 100644
-index 000000000000..a93d676604f9
+index 0000000..a93d676
 --- /dev/null
 +++ b/libunwind/libunwind.pc.in<http://libunwind.pc.in>
 @@ -0,0 +1,9 @@
@@ -33,7 +33,7 @@ index 000000000000..a93d676604f9
 +Libs: -lunwind
 diff --git a/llvm/tools/llvm-config/llvm-config b/llvm/tools/llvm-config/llvm-config
 new file mode 100644
-index 000000000000..6a0dd54b8eab
+index 0000000..0578773
 --- /dev/null
 +++ b/llvm/tools/llvm-config/llvm-config
 @@ -0,0 +1,15 @@
diff --git a/meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch b/meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
similarity index 90%
rename from meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
rename to meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
index 934d5adc50..55ad603b7c 100644
--- a/meta/recipes-devtools/clang/clang/0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
+++ b/meta/recipes-devtools/clang/clang/0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
@@ -1,7 +1,8 @@
-From a2171be64a181e0b263fc8ec31a760193651203c Mon Sep 17 00:00:00 2001
+From b9565c7e6525f3ca20df3171c36698b521a45594 Mon Sep 17 00:00:00 2001
 From: Martin Jansa <martin.jansa@gmail.com<mailto:martin.jansa@gmail.com>>
 Date: Fri, 13 Sep 2024 13:38:08 +0200
-Subject: [PATCH] scan-build-py: respect LLVM_LIBDIR_SUFFIX like other tools do
+Subject: [PATCH] scan-build-py: respect LLVM_LIBDIR_SUFFIX like other
+ tools do

 * other libraries are installed in 'lib64' or 'lib32' based on
   LLVM_LIBDIR_SUFFIX value, but libscanbuild files were always
@@ -11,13 +12,13 @@ Upstream-Status: Submitted [https://github.com/llvm/llvm-project/pull/108549]

 Signed-off-by: Martin Jansa <martin.jansa@gmail.com<mailto:martin.jansa@gmail.com>>
 ---
- clang/tools/scan-build-py/CMakeLists.txt | 26 ++++++++++++------------
- 1 file changed, 13 insertions(+), 13 deletions(-)
+ clang/tools/scan-build-py/CMakeLists.txt | 32 ++++++++++++------------
+ 1 file changed, 16 insertions(+), 16 deletions(-)

-Index: llvm-project-22.1.2.src/clang/tools/scan-build-py/CMakeLists.txt
-===================================================================
---- llvm-project-22.1.2.src.orig/clang/tools/scan-build-py/CMakeLists.txt
-+++ llvm-project-22.1.2.src/clang/tools/scan-build-py/CMakeLists.txt
+diff --git a/clang/tools/scan-build-py/CMakeLists.txt b/clang/tools/scan-build-py/CMakeLists.txt
+index 84087a9..9647642 100644
+--- a/clang/tools/scan-build-py/CMakeLists.txt
++++ b/clang/tools/scan-build-py/CMakeLists.txt
 @@ -80,52 +80,52 @@ if(CLANG_INSTALL_SCANBUILDPY)
    endforeach()

diff --git a/meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch b/meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
rename to meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
index fe24fe051b..b3fb642742 100644
--- a/meta/recipes-devtools/clang/clang/0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
+++ b/meta/recipes-devtools/clang/clang/0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
@@ -1,4 +1,4 @@
-From 6b1f360c66b60c4bb639057590a8b2162d3bcf6b Mon Sep 17 00:00:00 2001
+From f68925e7c31fa4bdd684a4ab44fd1350bb43205b Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Thu, 13 Mar 2025 00:30:38 -0700
 Subject: [PATCH] compiler-rt: Do not pass --target to clang compiler
@@ -13,7 +13,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 4 deletions(-)

 diff --git a/compiler-rt/lib/fuzzer/CMakeLists.txt b/compiler-rt/lib/fuzzer/CMakeLists.txt
-index a57e2fe46245..2928ed2ab6d5 100644
+index 2da488d..9af4410 100644
 --- a/compiler-rt/lib/fuzzer/CMakeLists.txt
 +++ b/compiler-rt/lib/fuzzer/CMakeLists.txt
 @@ -140,10 +140,6 @@ if(OS_NAME MATCHES "Android|Linux|Fuchsia" AND
diff --git a/meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch b/meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
similarity index 92%
rename from meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
rename to meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
index 413bc3f275..28d0567e15 100644
--- a/meta/recipes-devtools/clang/clang/0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
+++ b/meta/recipes-devtools/clang/clang/0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
@@ -1,4 +1,4 @@
-From 281cd05306cbfa5744e4a1f3ebf5c745324efe7a Mon Sep 17 00:00:00 2001
+From bf8a65efcdce65143081785b9ed8759d60be1bd4 Mon Sep 17 00:00:00 2001
 From: Alexander Kanavin <alex.kanavin@gmail.com<mailto:alex.kanavin@gmail.com>>
 Date: Fri, 27 Nov 2020 10:11:08 +0000
 Subject: [PATCH] AsmMatcherEmitter: sort ClassInfo lists by name as well
@@ -14,7 +14,7 @@ Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com<mailto:alex.kanavin@gmail.com>>
  1 file changed, 4 insertions(+), 1 deletion(-)

 diff --git a/llvm/utils/TableGen/AsmMatcherEmitter.cpp b/llvm/utils/TableGen/AsmMatcherEmitter.cpp
-index e6085af5aa91..b0180638c754 100644
+index 4af5c85..917aeec 100644
 --- a/llvm/utils/TableGen/AsmMatcherEmitter.cpp
 +++ b/llvm/utils/TableGen/AsmMatcherEmitter.cpp
 @@ -384,7 +384,10 @@ public:
diff --git a/meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch b/meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
similarity index 92%
rename from meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
rename to meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
index e059748873..7724af8009 100644
--- a/meta/recipes-devtools/clang/clang/0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
+++ b/meta/recipes-devtools/clang/clang/0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
@@ -1,4 +1,4 @@
-From cbc2595eed96fa7de77162e4c7b99681579d01ef Mon Sep 17 00:00:00 2001
+From f58186cc6ba2fff4d2e9fb624a904b1c5a4f7733 Mon Sep 17 00:00:00 2001
 From: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com<mailto:dmitry.baryshkov@oss.qualcomm.com>>
 Date: Wed, 2 Apr 2025 17:05:17 +0300
 Subject: [PATCH] llvm-config: remove LLVM_LDFLAGS from --ldflags output
@@ -18,7 +18,7 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 1 insertion(+), 1 deletion(-)

 diff --git a/llvm/tools/llvm-config/llvm-config.cpp b/llvm/tools/llvm-config/llvm-config.cpp
-index 0a3f51ae2b83..5c95a1f3ff24 100644
+index 64795e9..3e57005 100644
 --- a/llvm/tools/llvm-config/llvm-config.cpp
 +++ b/llvm/tools/llvm-config/llvm-config.cpp
 @@ -576,7 +576,7 @@ int main(int argc, char **argv) {
diff --git a/meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch b/meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
similarity index 95%
rename from meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
rename to meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
index 52bdeaf9d5..a1847f99f9 100644
--- a/meta/recipes-devtools/clang/clang/0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
+++ b/meta/recipes-devtools/clang/clang/0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
@@ -1,4 +1,4 @@
-From 3a486a17b697c65cdc7d2c17d9e14f2bfc2be911 Mon Sep 17 00:00:00 2001
+From 9046478db7833765487e66d5a3706b7cb67f1ee2 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Sat, 10 May 2025 14:03:12 -0700
 Subject: [PATCH] compiler-rt: Exclude sync_fetch_and_* for any pre-ARMv6
@@ -40,10 +40,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 12 insertions(+)

 diff --git a/compiler-rt/lib/builtins/CMakeLists.txt b/compiler-rt/lib/builtins/CMakeLists.txt
-index b3a44ea3c3b3..4a328ab0ca26 100644
+index eb108d7..4041119 100644
 --- a/compiler-rt/lib/builtins/CMakeLists.txt
 +++ b/compiler-rt/lib/builtins/CMakeLists.txt
-@@ -975,6 +975,18 @@ else ()
+@@ -1082,6 +1082,18 @@ else ()
          ${TARGET_${arch}_CFLAGS})
        list(JOIN CMAKE_REQUIRED_FLAGS " " CMAKE_REQUIRED_FLAGS)
        message(STATUS "Performing additional configure checks with target flags: ${CMAKE_REQUIRED_FLAGS}")
diff --git a/meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch b/meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
rename to meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
index b0aae5457a..d3a9a6c308 100644
--- a/meta/recipes-devtools/clang/clang/0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
+++ b/meta/recipes-devtools/clang/clang/0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch
@@ -1,7 +1,7 @@
-From b71c398a1b10b29886c2db2a920f476fec6f7de2 Mon Sep 17 00:00:00 2001
+From aab77dfb9c2e1a118ffb5bd690f34bf93b6f3f36 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Thu, 22 May 2025 21:50:45 -0700
-Subject: [PATCH] [compiler-rt] Hardcode uptr/sptr typedefs on Mips/Linux
+Subject: [PATCH] Hardcode uptr/sptr typedefs on Mips/Linux

 Sanitizer build on Mips/Linux faills to build due to assertion errors
 mismatched definitions. This is due to inconsistent definitions of
@@ -21,10 +21,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 1 insertion(+), 1 deletion(-)

 diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h b/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
-index c719e2a8ef60..60b997e653c4 100644
+index c694897..08f6d35 100644
 --- a/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
 +++ b/compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h
-@@ -139,7 +139,7 @@
+@@ -143,7 +143,7 @@
  namespace __sanitizer {

  #if defined(__UINTPTR_TYPE__)
diff --git a/meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch b/meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
similarity index 89%
rename from meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
rename to meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
index 57003dcf56..faae71645a 100644
--- a/meta/recipes-devtools/clang/clang/0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
+++ b/meta/recipes-devtools/clang/clang/0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
@@ -1,4 +1,4 @@
-From 9ace97c0c2df52d823c9d5345cca0251bf2ccf16 Mon Sep 17 00:00:00 2001
+From cffcea54bf4605d958407edb233fffdbe730f4af Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Sun, 27 Jul 2025 19:12:13 -0700
 Subject: [PATCH] Revert "[libc++] Remap headers in the debug info when
@@ -19,10 +19,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 5 deletions(-)

 diff --git a/libcxx/include/CMakeLists.txt b/libcxx/include/CMakeLists.txt
-index 787cfffa5019..d73bcd852a1e 100644
+index b40f586..7bd7622 100644
 --- a/libcxx/include/CMakeLists.txt
 +++ b/libcxx/include/CMakeLists.txt
-@@ -1718,11 +1718,6 @@ add_dependencies(cxx-headers generate-cxx-headers)
+@@ -1728,11 +1728,6 @@ add_dependencies(cxx-headers generate-cxx-headers)
  target_include_directories(cxx-headers INTERFACE ${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}
                                                   ${LIBCXX_GENERATED_INCLUDE_DIR})

diff --git a/meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch b/meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
similarity index 86%
rename from meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
rename to meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
index 0cdb2ad668..af9564053c 100644
--- a/meta/recipes-devtools/clang/clang/0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
+++ b/meta/recipes-devtools/clang/clang/0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
@@ -1,4 +1,4 @@
-From 53da129f7986c5bd310f4f4a8236987df7e073c6 Mon Sep 17 00:00:00 2001
+From b6a9ddd0ba2d8bd14871c135157f3878a9d629c1 Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@arm.com<mailto:ross.burton@arm.com>>
 Date: Mon, 29 Sep 2025 14:44:05 +0100
 Subject: [PATCH] Don't expose LLVM_HAVE_OPT_VIEWER_MODULES externally
@@ -14,10 +14,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 1 deletion(-)

 diff --git a/llvm/cmake/modules/LLVMConfig.cmake.in<http://LLVMConfig.cmake.in> b/llvm/cmake/modules/LLVMConfig.cmake.in<http://LLVMConfig.cmake.in>
-index 70c807abea98..5603c9215332 100644
+index 6f5fcc6..ce07563 100644
 --- a/llvm/cmake/modules/LLVMConfig.cmake.in<http://LLVMConfig.cmake.in>
 +++ b/llvm/cmake/modules/LLVMConfig.cmake.in<http://LLVMConfig.cmake.in>
-@@ -137,7 +137,6 @@ set(LLVM_DEFINITIONS "@LLVM_DEFINITIONS@")
+@@ -145,7 +145,6 @@ set(LLVM_DEFINITIONS "@LLVM_DEFINITIONS@")
  set(LLVM_BINARY_DIR "@LLVM_CONFIG_BINARY_DIR@")
  set(LLVM_CMAKE_DIR "@LLVM_CONFIG_CMAKE_DIR@")
  set(LLVM_TOOLS_BINARY_DIR "@LLVM_CONFIG_TOOLS_BINARY_DIR@")
diff --git a/meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch b/meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
similarity index 81%
rename from meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
rename to meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
index 5efe043eaf..690791c5e3 100644
--- a/meta/recipes-devtools/clang/clang/0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
+++ b/meta/recipes-devtools/clang/clang/0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch
@@ -1,7 +1,7 @@
-From de58b9bbc8c52299ff22c4f0ab21e3878d411669 Mon Sep 17 00:00:00 2001
+From a55e7674203ffcb42e4e3ee4c8cf7aa964aee086 Mon Sep 17 00:00:00 2001
 From: Ross Burton <ross.burton@arm.com<mailto:ross.burton@arm.com>>
 Date: Sat, 11 Oct 2025 16:01:50 -0700
-Subject: [PATCH] [clang] Only build clang-tblgen if it is actually needed
+Subject: [PATCH] Only build clang-tblgen if it is actually needed

 It's possible to build clang with an existing clang-tblgen (common when
 cross-compiling, for instance) by setting CLANG_TABLEGEN_EXE.  If this
@@ -16,10 +16,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 3 insertions(+), 1 deletion(-)

 diff --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt
-index e4cb1a359620..b650b3b986f4 100644
+index 89f584c..bd7ebc3 100644
 --- a/clang/CMakeLists.txt
 +++ b/clang/CMakeLists.txt
-@@ -479,7 +479,9 @@ option(CLANG_ENABLE_HLSL "Include HLSL build products" Off)
+@@ -531,7 +531,9 @@ option(CLANG_ENABLE_HLSL "Include HLSL build products" Off)
  # While HLSL support is experimental this should stay hidden.
  mark_as_advanced(CLANG_ENABLE_HLSL)

diff --git a/meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch b/meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
similarity index 93%
rename from meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
rename to meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
index 583e91e497..6081f2d7b4 100644
--- a/meta/recipes-devtools/clang/clang/0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
+++ b/meta/recipes-devtools/clang/clang/0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
@@ -1,4 +1,4 @@
-From bca77d818187e68989dfa9e386b38632b76a477e Mon Sep 17 00:00:00 2001
+From b383508d002bb41ac979ab356f73fcf0ae97ca00 Mon Sep 17 00:00:00 2001
 From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
 Date: Tue, 28 Oct 2025 15:44:49 -0700
 Subject: [PATCH] llvm-libgcc: Fix symlink path for libcc when
@@ -33,10 +33,10 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
  1 file changed, 13 insertions(+), 3 deletions(-)

 diff --git a/llvm-libgcc/CMakeLists.txt b/llvm-libgcc/CMakeLists.txt
-index 47208fc19869..54009c1104c3 100644
+index a297447..1ae9167 100644
 --- a/llvm-libgcc/CMakeLists.txt
 +++ b/llvm-libgcc/CMakeLists.txt
-@@ -124,11 +124,21 @@ target_link_libraries(unwind_shared PUBLIC
+@@ -133,11 +133,21 @@ target_link_libraries(unwind_shared PUBLIC
  #===============================================================================

  get_compiler_rt_install_dir(${COMPILER_RT_DEFAULT_TARGET_ARCH} install_dir_builtins)
@@ -60,7 +60,7 @@ index 47208fc19869..54009c1104c3 100644
    string(PREPEND install_dir_builtins "../")
  endif()
  set(LLVM_LIBGCC_COMPILER_RT ${install_dir_builtins}/libclang_rt.builtins${builtins_suffix}.a)
-@@ -137,7 +147,7 @@ add_custom_target(llvm-libgcc ALL
+@@ -146,7 +156,7 @@ add_custom_target(llvm-libgcc ALL
    DEPENDS unwind_shared unwind_static clang_rt.builtins-${COMPILER_RT_DEFAULT_TARGET_ARCH}
    COMMAND ${CMAKE_COMMAND} -E create_symlink ${LLVM_LIBGCC_COMPILER_RT} libgcc.a
    COMMAND ${CMAKE_COMMAND} -E create_symlink libunwind.a libgcc_eh.a
diff --git a/meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch b/meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
similarity index 91%
rename from meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
rename to meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
index a2a7fa80f1..ecaaa738a7 100644
--- a/meta/recipes-devtools/clang/clang/0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
+++ b/meta/recipes-devtools/clang/clang/0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
@@ -1,7 +1,8 @@
-From b818a92ac171e80e39ad9e99d1f862d23f2bb5b3 Mon Sep 17 00:00:00 2001
+From 7da49a0e48fa77d38548f8f1dedc7cb1bb8dce53 Mon Sep 17 00:00:00 2001
 From: "mark.yang" <mark.yang@lge.com<mailto:mark.yang@lge.com>>
 Date: Tue, 14 Apr 2026 16:17:01 +0900
-Subject: [PATCH] Consolidate and fix sysroot-based compiler-rt search paths
+Subject: [PATCH] Consolidate and fix sysroot-based compiler-rt search
+ paths

 Consolidate patches 0008 and 0033 into a single patch with a fix for
 native builds.
@@ -41,10 +42,10 @@ Signed-off-by: mark.yang <mark.yang@lge.com<mailto:mark.yang@lge.com>>
  1 file changed, 28 insertions(+), 3 deletions(-)

 diff --git a/clang/lib/Driver/ToolChain.cpp b/clang/lib/Driver/ToolChain.cpp
-index 77a2c73f0..ac28b51c4 100644
+index f894a06..eceada5 100644
 --- a/clang/lib/Driver/ToolChain.cpp
 +++ b/clang/lib/Driver/ToolChain.cpp
-@@ -15,6 +15,7 @@
+@@ -16,6 +16,7 @@
  #include "ToolChains/InterfaceStubs.h"
  #include "clang/Basic/ObjCRuntime.h"
  #include "clang/Basic/Sanitizers.h"
@@ -52,7 +53,7 @@ index 77a2c73f0..ac28b51c4 100644
  #include "clang/Config/config.h"
  #include "clang/Driver/Action.h"
  #include "clang/Driver/CommonArgs.h"
-@@ -723,7 +724,15 @@ StringRef ToolChain::getOSLibName() const {
+@@ -872,7 +873,15 @@ StringRef ToolChain::getOSLibName() const {
  }

  std::string ToolChain::getCompilerRTPath() const {
@@ -69,7 +70,7 @@ index 77a2c73f0..ac28b51c4 100644
    if (isBareMetal()) {
      llvm::sys::path::append(Path, "lib", getOSLibName());
      if (!SelectedMultilibs.empty()) {
-@@ -1021,7 +1030,15 @@ ToolChain::getTargetSubDirPath(StringRef BaseDir) const {
+@@ -1179,7 +1188,15 @@ std::optional<std::string> ToolChain::getDefaultIntrinsicModuleDir() const {
  }

  std::optional<std::string> ToolChain::getRuntimePath() const {
@@ -86,7 +87,7 @@ index 77a2c73f0..ac28b51c4 100644
    llvm::sys::path::append(P, "lib");
    if (auto Ret = getTargetSubDirPath(P))
      return Ret;
-@@ -1049,7 +1066,15 @@ ToolChain::path_list ToolChain::getArchSpecificLibPaths() const {
+@@ -1207,7 +1224,15 @@ ToolChain::path_list ToolChain::getArchSpecificLibPaths() const {
    path_list Paths;

    auto AddPath = [&](const ArrayRef<StringRef> &SS) {
diff --git a/meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch b/meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
similarity index 83%
rename from meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch
rename to meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
index 9b4e29ff64..5e53d43944 100644
--- a/meta/recipes-devtools/clang/clang/0042-guard-clang-tools-extra-test.patch
+++ b/meta/recipes-devtools/clang/clang/0034-guard-clang-tools-extra-test.patch
@@ -1,3 +1,8 @@
+From 9463b5d24fc62372fc2731d4d4665c64c72b55b2 Mon Sep 17 00:00:00 2001
+From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>
+Date: Wed, 19 Aug 2026 22:46:10 +0530
+Subject: [PATCH] guard clang-tools-extra test
+
 clang-tools-extra tests depend on the llvm-bcanalyzer CMake target, which
 exists in LLVM's CMake project but is not visible when Clang is built
 separately. To run clang tests, disable clang-tools-extra tests for now.
@@ -22,30 +27,49 @@ Without this patch when CLANG_INCLUDE_TESTS is ON got the following error
 -------------------------------------------------------------------------------

 Upstream-Status: Inappropriate [OE-Specific]
+
 Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>
+---
+ clang-tools-extra/CMakeLists.txt                 | 4 ++--
+ clang-tools-extra/clangd/CMakeLists.txt          | 2 +-
+ clang-tools-extra/include-cleaner/CMakeLists.txt | 2 +-
+ 3 files changed, 4 insertions(+), 4 deletions(-)

 diff --git a/clang-tools-extra/CMakeLists.txt b/clang-tools-extra/CMakeLists.txt
-index 6b6f2b1..26e4c10 100644
+index 87050db..3824129 100644
 --- a/clang-tools-extra/CMakeLists.txt
 +++ b/clang-tools-extra/CMakeLists.txt
-@@ -8,7 +8,7 @@ include(GNUInstallDirs)
+@@ -8,7 +8,7 @@ option(CLANG_TIDY_ENABLE_STATIC_ANALYZER
  option(CLANG_TIDY_ENABLE_QUERY_BASED_CUSTOM_CHECKS
    "Enable query-based custom checks in clang-tidy" ON)
-
+
 -if(CLANG_INCLUDE_TESTS)
 +if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
    umbrella_lit_testsuite_begin(check-clang-tools)
-
+
    option(CLANG_TOOLS_TEST_USE_VG "Run Clang tools' tests under Valgrind" OFF)
 @@ -45,7 +45,7 @@ if (CLANG_ENABLE_CLANGD)
  endif()
-
+
  # Add the common testsuite after all the tools.
 -if(CLANG_INCLUDE_TESTS)
 +if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
    add_subdirectory(test)
    add_subdirectory(unittests)
    umbrella_lit_testsuite_end(check-clang-tools)
+diff --git a/clang-tools-extra/clangd/CMakeLists.txt b/clang-tools-extra/clangd/CMakeLists.txt
+index 890562d..c4d6623 100644
+--- a/clang-tools-extra/clangd/CMakeLists.txt
++++ b/clang-tools-extra/clangd/CMakeLists.txt
+@@ -217,7 +217,7 @@ endif()
+ option(CLANGD_BUILD_DEXP "Build the dexp tool as part of Clangd" ON)
+ llvm_canonicalize_cmake_booleans(CLANGD_BUILD_DEXP)
+
+-if(CLANG_INCLUDE_TESTS)
++if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
+   add_subdirectory(test)
+   add_subdirectory(unittests)
+ endif()
 diff --git a/clang-tools-extra/include-cleaner/CMakeLists.txt b/clang-tools-extra/include-cleaner/CMakeLists.txt
 index dc147f9..4855577 100644
 --- a/clang-tools-extra/include-cleaner/CMakeLists.txt
@@ -59,16 +83,3 @@ index dc147f9..4855577 100644
    add_subdirectory(test)
    add_subdirectory(unittests)
  endif()
-diff --git a/clang-tools-extra/clangd/CMakeLists.txt b/clang-tools-extra/clangd/CMakeLists.txt
-index a1e9da4..94dcb96 100644
---- a/clang-tools-extra/clangd/CMakeLists.txt
-+++ b/clang-tools-extra/clangd/CMakeLists.txt
-@@ -215,7 +215,7 @@ endif()
- option(CLANGD_BUILD_DEXP "Build the dexp tool as part of Clangd" ON)
- llvm_canonicalize_cmake_booleans(CLANGD_BUILD_DEXP)
-
--if(CLANG_INCLUDE_TESTS)
-+if(CLANG_TOOLS_EXTRA_INCLUDE_TESTS)
-   add_subdirectory(test)
-   add_subdirectory(unittests)
- endif()
diff --git a/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch b/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
deleted file mode 100644
index 6021f736ff..0000000000
--- a/meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 051b3bfa1e0e5cfed4a02318e330b38b0090cc49 Mon Sep 17 00:00:00 2001
-From: Serge Pavlov <sepavloff@gmail.com<mailto:sepavloff@gmail.com>>
-Date: Fri, 25 Jul 2025 13:35:19 +0700
-Subject: [PATCH] Prevent revisiting block when searching for noreturn vars
-
-When searching for noreturn variable initializations, do not visit CFG
-blocks that are already visited, it prevents hanging  the analysis.
-
-It must fix https://github.com/llvm/llvm-project/issues/150336.
-
-Upstream-Status: Submitted [https://github.com/llvm/llvm-project/pull/150582]
-Signed-off-by: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
----
- clang/test/SemaCXX/noreturn-vars.cpp | 17 +++++++++++++++++
- 1 file changed, 17 insertions(+)
-
-diff --git a/clang/test/SemaCXX/noreturn-vars.cpp b/clang/test/SemaCXX/noreturn-vars.cpp
-index ca65fcf5ca31..1bf074149f04 100644
---- a/clang/test/SemaCXX/noreturn-vars.cpp
-+++ b/clang/test/SemaCXX/noreturn-vars.cpp
-@@ -225,3 +225,20 @@ extern void abc_02(func_type *);
-   abc_02(&func_ptr);
-   func_ptr();
- } // expected-warning {{function declared 'noreturn' should not return}}
-+
-+namespace Issue150336 {
-+void free(void *);
-+typedef void (*sel_freefunc)(void *);
-+struct gmx_ana_selmethod_t {
-+  sel_freefunc free;
-+  int nparams;
-+  int *param;
-+};
-+void gmx_selelem_free_method(struct gmx_ana_selmethod_t* method, void* mdata) {
-+    sel_freefunc free_func = 0;
-+    for (int i = 0; i < method->nparams; ++i)
-+        free(&method->param[i]);
-+    if (mdata && free_func)
-+        free_func(mdata);
-+}
-+}
diff --git a/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch b/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
new file mode 100644
index 0000000000..df35636055
--- /dev/null
+++ b/meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
@@ -0,0 +1,36 @@
+From: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>
+Date: Fri, 29 Aug 2026 13:55:00 +0530
+Subject: [PATCH] libc: Disable float16 on 32-bit x86 without SSE2
+
+GCC 16 defines __FLT16_MANT_DIG__ when targeting i686 even though
+_Float16 is only usable on x86-32 with SSE2 enabled. The float16
+detection in float16-macros.h keys on that macro, so the shared f16
+math headers are compiled on plain i686 and every use of _Float16
+fails:
+
+  libc/src/__support/FPUtil/BasicOperations.h:63:67:
+      error: SSE register return with SSE2 disabled
+  libc/src/__support/math/acosf16.h:73:14:
+      error: invalid conversion from type '_Float16' without option '-msse2'
+
+Since llvm/lib/Support/APFloat.cpp started including shared/math.h,
+this breaks the LLVM build itself for 32-bit x86 baselines older than
+SSE2 (e.g. -march=pentiumpro), as used by Yocto/OpenEmbedded multilib.
+
+Require SSE2 on 32-bit x86 in the guard, matching the existing
+exclusions for 32-bit Arm and RISC-V. Targets with SSE2 are unaffected.
+
+Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/05da143c63d333420b99eab198e1a89c97480929]
+Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>
+---
+--- a/libc/include/llvm-libc-macros/float16-macros.h   2026-08-29 13:55:04.771442947 +0530
++++ b/libc/include/llvm-libc-macros/float16-macros.h   2026-08-29 13:55:04.773991812 +0530
+@@ -15,7 +15,7 @@
+     (!defined(__GNUC__) || __GNUC__ >= 13 ||                                   \
+      (defined(__clang__) && __clang_major__ >= 12)) &&                         \
+     !defined(__arm__) && !defined(_M_ARM) && !defined(__riscv) &&              \
+-    !defined(_WIN32)
++    !defined(_WIN32) && (!defined(__i386__) || defined(__SSE2__))
+ #define LIBC_TYPES_HAS_FLOAT16
+
+ // TODO: This would no longer be required if HdrGen let us guard function
diff --git a/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch b/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
deleted file mode 100644
index 493948acef..0000000000
--- a/meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
+++ /dev/null
@@ -1,274 +0,0 @@
-From 82f18b02d9fec1bcc225a92251466ffee82f56b5 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com<mailto:raj.khem@gmail.com>>
-Date: Fri, 20 Mar 2026 14:22:17 -0700
-Subject: [PATCH] [Clang] Rename UNUSED and UNKNOWN elements of OffloadArch enum to avoid
- macro collisions
-
-OffloadArch uses enumerator named `UNUSED` `UNKNOWN`, which are common macro name
-in external codebases (e.g. Mesa defines UNUSED as an attribute helper). If such
-a macro is visible when including clang/Basic/OffloadArch.h, the preprocessor
-expands the token inside the enum and breaks compilation of the installed Clang
-headers.
-
-Rename the enumerator to `Unused` and `Unknown` and update all in-tree references. This is a
-spelling-only change (no behavioral impact) and mirrors the existing approach
-used for SM_32_ to avoid macro clashes.
-
-Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/5bc3d1966b2d0b300c338d85bb38e356f0d12a8c]
-Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>
-
-diff --git a/clang/include/clang/Basic/OffloadArch.h b/clang/include/clang/Basic/OffloadArch.h
-index ea665b1..970487c 100644
---- a/clang/include/clang/Basic/OffloadArch.h
-+++ b/clang/include/clang/Basic/OffloadArch.h
-@@ -16,8 +16,8 @@ class StringRef;
- namespace clang {
-
- enum class OffloadArch {
--  UNUSED,
--  UNKNOWN,
-+  Unused,
-+  Unknown,
-   // TODO: Deprecate and remove GPU architectures older than sm_52.
-   SM_20,
-   SM_21,
-@@ -145,7 +145,7 @@ const char *OffloadArchToString(OffloadArch A);
- const char *OffloadArchToVirtualArchString(OffloadArch A);
-
- // Convert a string to an OffloadArch enum value. Returns
--// OffloadArch::UNKNOWN if the string is not recognized.
-+// OffloadArch::Unknown if the string is not recognized.
- OffloadArch StringToOffloadArch(llvm::StringRef S);
-
- } // namespace clang
-diff --git a/clang/lib/Basic/Cuda.cpp b/clang/lib/Basic/Cuda.cpp
-index 514fa2f..7884910 100644
---- a/clang/lib/Basic/Cuda.cpp
-+++ b/clang/lib/Basic/Cuda.cpp
-@@ -75,7 +75,7 @@ CudaVersion ToCudaVersion(llvm::VersionTuple Version) {
- }
-
- CudaVersion MinVersionForOffloadArch(OffloadArch A) {
--  if (A == OffloadArch::UNKNOWN)
-+  if (A == OffloadArch::Unknown)
-     return CudaVersion::UNKNOWN;
-
-   // AMD GPUs do not depend on CUDA versions.
-@@ -141,7 +141,7 @@ CudaVersion MaxVersionForOffloadArch(OffloadArch A) {
-     return CudaVersion::NEW;
-
-   switch (A) {
--  case OffloadArch::UNKNOWN:
-+  case OffloadArch::Unknown:
-     return CudaVersion::UNKNOWN;
-   case OffloadArch::SM_20:
-   case OffloadArch::SM_21:
-diff --git a/clang/lib/Basic/OffloadArch.cpp b/clang/lib/Basic/OffloadArch.cpp
-index 05177f1..f3bbe64 100644
---- a/clang/lib/Basic/OffloadArch.cpp
-+++ b/clang/lib/Basic/OffloadArch.cpp
-@@ -17,7 +17,7 @@ struct OffloadArchToStringMap {
- #define GFX(gpu) {OffloadArch::GFX##gpu, "gfx" #gpu, "compute_amdgcn"}
- static const OffloadArchToStringMap ArchNames[] = {
-     // clang-format off
--    {OffloadArch::UNUSED, "", ""},
-+    {OffloadArch::Unused, "", ""},
-     SM(20), {OffloadArch::SM_21, "sm_21", "compute_20"}, // Fermi
-     SM(30), {OffloadArch::SM_32_, "sm_32", "compute_32"}, SM(35), SM(37),  // Kepler
-     SM(50), SM(52), SM(53),          // Maxwell
-@@ -132,7 +132,7 @@ OffloadArch StringToOffloadArch(llvm::StringRef S) {
-         return S == Map.ArchName;
-       });
-   if (Result == std::end(ArchNames))
--    return OffloadArch::UNKNOWN;
-+    return OffloadArch::Unknown;
-   return Result->Arch;
- }
-
-diff --git a/clang/lib/Basic/Targets/NVPTX.cpp b/clang/lib/Basic/Targets/NVPTX.cpp
-index 6526eef..9584f8a 100644
---- a/clang/lib/Basic/Targets/NVPTX.cpp
-+++ b/clang/lib/Basic/Targets/NVPTX.cpp
-@@ -64,7 +64,7 @@ NVPTXTargetInfo::NVPTXTargetInfo(const llvm::Triple &Triple,
-   // Define available target features
-   // These must be defined in sorted order!
-   NoAsmVariants = true;
--  GPU = OffloadArch::UNUSED;
-+  GPU = OffloadArch::Unused;
-
-   // PTX supports f16 as a fundamental type.
-   HasFastHalfType = true;
-diff --git a/clang/lib/Basic/Targets/NVPTX.h b/clang/lib/Basic/Targets/NVPTX.h
-index 9bd0cc3..eeffb0e 100644
---- a/clang/lib/Basic/Targets/NVPTX.h
-+++ b/clang/lib/Basic/Targets/NVPTX.h
-@@ -87,7 +87,7 @@ public:
-   initFeatureMap(llvm::StringMap<bool> &Features, DiagnosticsEngine &Diags,
-                  StringRef CPU,
-                  const std::vector<std::string> &FeaturesVec) const override {
--    if (GPU != OffloadArch::UNUSED)
-+    if (GPU != OffloadArch::Unused)
-       Features[OffloadArchToString(GPU)] = true;
-     // Only add PTX feature if explicitly requested. Otherwise, let the backend
-     // use the minimum required PTX version for the target SM.
-@@ -146,7 +146,7 @@ public:
-   }
-
-   bool isValidCPUName(StringRef Name) const override {
--    return StringToOffloadArch(Name) != OffloadArch::UNKNOWN;
-+    return StringToOffloadArch(Name) != OffloadArch::Unknown;
-   }
-
-   void fillValidCPUList(SmallVectorImpl<StringRef> &Values) const override {
-@@ -157,7 +157,7 @@ public:
-
-   bool setCPU(const std::string &Name) override {
-     GPU = StringToOffloadArch(Name);
--    return GPU != OffloadArch::UNKNOWN;
-+    return GPU != OffloadArch::Unknown;
-   }
-
-   void setSupportedOpenCLOpts() override {
-diff --git a/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp b/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
-index db0d56d..f78047d 100644
---- a/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
-+++ b/clang/lib/CodeGen/CGOpenMPRuntimeGPU.cpp
-@@ -2266,15 +2266,15 @@ bool CGOpenMPRuntimeGPU::hasAllocateAttributeForGlobalVar(const VarDecl *VD,
- // Get current OffloadArch and ignore any unknown values
- static OffloadArch getOffloadArch(CodeGenModule &CGM) {
-   if (!CGM.getTarget().hasFeature("ptx"))
--    return OffloadArch::UNKNOWN;
-+    return OffloadArch::Unknown;
-   for (const auto &Feature : CGM.getTarget().getTargetOpts().FeatureMap) {
-     if (Feature.getValue()) {
-       OffloadArch Arch = StringToOffloadArch(Feature.getKey());
--      if (Arch != OffloadArch::UNKNOWN)
-+      if (Arch != OffloadArch::Unknown)
-         return Arch;
-     }
-   }
--  return OffloadArch::UNKNOWN;
-+  return OffloadArch::Unknown;
- }
-
- /// Check to see if target architecture supports unified addressing which is
-@@ -2382,8 +2382,8 @@ void CGOpenMPRuntimeGPU::processRequiresDirective(const OMPRequiresDecl *D) {
-       case OffloadArch::Generic:
-       case OffloadArch::GRANITERAPIDS:
-       case OffloadArch::BMG_G21:
--      case OffloadArch::UNUSED:
--      case OffloadArch::UNKNOWN:
-+      case OffloadArch::Unused:
-+      case OffloadArch::Unknown:
-         break;
-       case OffloadArch::LAST:
-         llvm_unreachable("Unexpected GPU arch.");
-diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Driver.cpp
-index eb3f9cb..c8894a1 100644
---- a/clang/lib/Driver/Driver.cpp
-+++ b/clang/lib/Driver/Driver.cpp
-@@ -946,7 +946,7 @@ inferOffloadToolchains(Compilation &C, Action::OffloadKind Kind) {
-   llvm::DenseSet<llvm::StringRef> Triples;
-   for (llvm::StringRef Arch : Archs) {
-     OffloadArch ID = StringToOffloadArch(Arch);
--    if (ID == OffloadArch::UNKNOWN)
-+    if (ID == OffloadArch::Unknown)
-       ID = StringToOffloadArch(
-           getProcessorFromTargetID(llvm::Triple("amdgcn-amd-amdhsa"), Arch));
-
-@@ -961,12 +961,12 @@ inferOffloadToolchains(Compilation &C, Action::OffloadKind Kind) {
-       return llvm::DenseSet<llvm::StringRef>();
-     }
-     if (Kind == Action::OFK_OpenMP &&
--        (ID == OffloadArch::UNKNOWN || ID == OffloadArch::UNUSED)) {
-+        (ID == OffloadArch::Unknown || ID == OffloadArch::Unused)) {
-       C.getDriver().Diag(clang::diag::err_drv_failed_to_deduce_target_from_arch)
-           << Arch;
-       return llvm::DenseSet<llvm::StringRef>();
-     }
--    if (ID == OffloadArch::UNKNOWN || ID == OffloadArch::UNUSED) {
-+    if (ID == OffloadArch::Unknown || ID == OffloadArch::Unused) {
-       C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
-           << "offload" << Arch;
-       return llvm::DenseSet<llvm::StringRef>();
-@@ -3305,7 +3305,7 @@ class OffloadingActionBuilder final {
-     bool Relocatable = false;
-
-     /// Default GPU architecture if there's no one specified.
--    OffloadArch DefaultOffloadArch = OffloadArch::UNKNOWN;
-+    OffloadArch DefaultOffloadArch = OffloadArch::Unknown;
-
-     /// Compilation unit ID specified by option '-fuse-cuid=' or'-cuid='.
-     const CUIDOptions &CUIDOpts;
-@@ -3407,7 +3407,7 @@ class OffloadingActionBuilder final {
-
-       // If we have a fat binary, add it to the list.
-       if (CudaFatBinary) {
--        AddTopLevel(CudaFatBinary, OffloadArch::UNUSED);
-+        AddTopLevel(CudaFatBinary, OffloadArch::Unused);
-         CudaDeviceActions.clear();
-         CudaFatBinary = nullptr;
-         return;
-@@ -4669,12 +4669,12 @@ static StringRef getCanonicalArchString(Compilation &C,
-   OffloadArch Arch =
-       StringToOffloadArch(getProcessorFromTargetID(Triple, ArchStr));
-   if (Triple.isNVPTX() &&
--      (Arch == OffloadArch::UNKNOWN || !IsNVIDIAOffloadArch(Arch))) {
-+      (Arch == OffloadArch::Unknown || !IsNVIDIAOffloadArch(Arch))) {
-     C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
-         << "CUDA" << ArchStr;
-     return StringRef();
-   } else if (Triple.isAMDGPU() &&
--             (Arch == OffloadArch::UNKNOWN || !IsAMDOffloadArch(Arch))) {
-+             (Arch == OffloadArch::Unknown || !IsAMDOffloadArch(Arch))) {
-     C.getDriver().Diag(clang::diag::err_drv_offload_bad_gpu_arch)
-         << "HIP" << ArchStr;
-     return StringRef();
-diff --git a/clang/lib/Driver/OffloadBundler.cpp b/clang/lib/Driver/OffloadBundler.cpp
-index f69ac41..6d446f2 100644
---- a/clang/lib/Driver/OffloadBundler.cpp
-+++ b/clang/lib/Driver/OffloadBundler.cpp
-@@ -95,7 +95,7 @@ OffloadTargetInfo::OffloadTargetInfo(const StringRef Target,
-       Components.size() == 6 ? Components.back() : "";
-   StringRef TargetId = TargetIdWithFeature.split(':').first;
-   if (!TargetId.empty() &&
--      clang::StringToOffloadArch(TargetId) != clang::OffloadArch::UNKNOWN)
-+      clang::StringToOffloadArch(TargetId) != clang::OffloadArch::Unknown)
-     this->TargetID = TargetIdWithFeature;
-   else
-     this->TargetID = "";
-diff --git a/clang/lib/Driver/ToolChains/Cuda.cpp b/clang/lib/Driver/ToolChains/Cuda.cpp
-index 6cc73ff..d97b926 100644
---- a/clang/lib/Driver/ToolChains/Cuda.cpp
-+++ b/clang/lib/Driver/ToolChains/Cuda.cpp
-@@ -319,7 +319,7 @@ void CudaInstallationDetector::AddCudaIncludeArgs(
-
- void CudaInstallationDetector::CheckCudaVersionSupportsArch(
-     OffloadArch Arch) const {
--  if (Arch == OffloadArch::UNKNOWN || Version == CudaVersion::UNKNOWN ||
-+  if (Arch == OffloadArch::Unknown || Version == CudaVersion::UNKNOWN ||
-       ArchsWithBadVersion[(int)Arch])
-     return;
-
-@@ -408,7 +408,7 @@ void NVPTX::Assembler::ConstructJob(Compilation &C, const JobAction &JA,
-
-   // Obtain architecture from the action.
-   OffloadArch gpu_arch = StringToOffloadArch(GPUArchName);
--  assert(gpu_arch != OffloadArch::UNKNOWN &&
-+  assert(gpu_arch != OffloadArch::Unknown &&
-          "Device action expected to have an architecture.");
-
-   // Check that our installation's ptxas supports gpu_arch.
-diff --git a/clang/lib/Sema/SemaDeclAttr.cpp b/clang/lib/Sema/SemaDeclAttr.cpp
-index 3f0ea5c..e6d3516 100644
---- a/clang/lib/Sema/SemaDeclAttr.cpp
-+++ b/clang/lib/Sema/SemaDeclAttr.cpp
-@@ -5732,7 +5732,7 @@ Sema::CreateLaunchBoundsAttr(const AttributeCommonInfo &CI, Expr *MaxThreads,
-   if (MaxBlocks) {
-     // '.maxclusterrank' ptx directive requires .target sm_90 or higher.
-     auto SM = getOffloadArch(Context.getTargetInfo());
--    if (SM == OffloadArch::UNKNOWN || SM < OffloadArch::SM_90) {
-+    if (SM == OffloadArch::Unknown || SM < OffloadArch::SM_90) {
-       Diag(MaxBlocks->getBeginLoc(), diag::warn_cuda_maxclusterrank_sm_90)
-           << OffloadArchToString(SM) << CI << MaxBlocks->getSourceRange();
-       // Ignore it by setting MaxBlocks to null;
diff --git a/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch b/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
deleted file mode 100644
index f458fd0cf8..0000000000
--- a/meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 5dbd0a05f64a43849a7edde95a0e5f2323cd1f9d Mon Sep 17 00:00:00 2001
-From: Khem Raj <khem.raj@oss.qualcomm.com<mailto:khem.raj@oss.qualcomm.com>>
-Date: Tue, 31 Mar 2026 19:33:29 -0700
-Subject: [PATCH] libcxxabi: declare __gnu_unwind_frame in cxa_personality
-
-ARM EHABI builds of libcxxabi fail with clang-22+ because
-cxa_personality.cpp calls __gnu_unwind_frame without a visible
-declaration, triggering:
-
-  error: use of undeclared identifier '__gnu_unwind_frame'
-
-Add an extern "C" forward declaration before the EHABI unwind helper
-so the source compiles correctly.
-
-Upstream-Status: Submitted [https://github.com/llvm/llvm-project/pull/189787]
-Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com<mailto:khem.raj@oss.qualcomm.com>>
----
- libcxxabi/src/cxa_personality.cpp | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/libcxxabi/src/cxa_personality.cpp b/libcxxabi/src/cxa_personality.cpp
-index 35f4e3807724..ddff277cc7b8 100644
---- a/libcxxabi/src/cxa_personality.cpp
-+++ b/libcxxabi/src/cxa_personality.cpp
-@@ -1116,6 +1116,8 @@ __gxx_personality_seh0(PEXCEPTION_RECORD ms_exc, void *this_frame,
-
- #else
-
-+extern "C" _Unwind_Reason_Code __gnu_unwind_frame(_Unwind_Exception*,
-+                                                  _Unwind_Context*);
- // Helper function to unwind one frame.
- // ARM EHABI 7.3 and 7.4: If the personality function returns _URC_CONTINUE_UNWIND, the
- // personality routine should update the virtual register set (VRS) according to the
diff --git a/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch b/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
deleted file mode 100644
index 39e27ac12f..0000000000
--- a/meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
+++ /dev/null
@@ -1,71 +0,0 @@
-From 965f9d87adb0a7376454374fbc140ab69bd796a9 Mon Sep 17 00:00:00 2001
-From: Florian Hahn <flo@fhahn.com<mailto:flo@fhahn.com>>
-Date: Fri, 27 Mar 2026 13:02:51 +0000
-Subject: [PATCH] [LoopUnroll] Use MapVector for deterministic iteration order.
- (#188821)
-
-NonLoopBlocksIDom determines the order we adjust the DT, impacting DRT
-child ordering.
-
-Similarly, ExitInfos order impacts the order of SetDest, which applies
-DT updates.
-
-The order impacts collectChildrenInLoop, which in turn impacts the we
-process BBs in LICM. And this in turn impacts the order in which we
-perform alias queries.
-
-If the order is not deterministic, we sometimes get different NumNoAlias
-statistic counts, and possibly also different IR, although I have not
-confirmed the latter.
-
-Upstream-Status: Backport [https://github.com/llvm/llvm-project/commit/965f9d87adb0a7376454374fbc140ab69bd796a9]
-Signed-off-by: Sunilkumar Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>
-Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>
-
----
- llvm/lib/Transforms/Utils/LoopPeel.cpp   | 3 ++-
- llvm/lib/Transforms/Utils/LoopUnroll.cpp | 3 ++-
- 2 files changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/llvm/lib/Transforms/Utils/LoopPeel.cpp b/llvm/lib/Transforms/Utils/LoopPeel.cpp
-index 91737b5c30533..4c67d5a9ae680 100644
---- a/llvm/lib/Transforms/Utils/LoopPeel.cpp
-+++ b/llvm/lib/Transforms/Utils/LoopPeel.cpp
-@@ -11,6 +11,7 @@
-
- #include "llvm/Transforms/Utils/LoopPeel.h"
- #include "llvm/ADT/DenseMap.h"
-+#include "llvm/ADT/MapVector.h"
- #include "llvm/ADT/SmallVector.h"
- #include "llvm/ADT/Statistic.h"
- #include "llvm/Analysis/Loads.h"
-@@ -1121,7 +1122,7 @@ void llvm::peelLoop(Loop *L, unsigned PeelCount, bool PeelLast, LoopInfo *LI,
-   // later. Immediate dominator of such block might change, because we add more
-   // routes which can lead to the exit: we can reach it from the peeled
-   // iterations too.
--  DenseMap<BasicBlock *, BasicBlock *> NonLoopBlocksIDom;
-+  MapVector<BasicBlock *, BasicBlock *> NonLoopBlocksIDom;
-   for (auto *BB : L->blocks()) {
-     auto *BBDomNode = DT.getNode(BB);
-     SmallVector<BasicBlock *, 16> ChildrenToUpdate;
-diff --git a/llvm/lib/Transforms/Utils/LoopUnroll.cpp b/llvm/lib/Transforms/Utils/LoopUnroll.cpp
-index 6a2ccbea996bf..ab35d217f0d93 100644
---- a/llvm/lib/Transforms/Utils/LoopUnroll.cpp
-+++ b/llvm/lib/Transforms/Utils/LoopUnroll.cpp
-@@ -17,6 +17,7 @@
-
- #include "llvm/ADT/ArrayRef.h"
- #include "llvm/ADT/DenseMap.h"
-+#include "llvm/ADT/MapVector.h"
- #include "llvm/ADT/STLExtras.h"
- #include "llvm/ADT/ScopedHashTable.h"
- #include "llvm/ADT/SetVector.h"
-@@ -515,7 +516,7 @@ llvm::UnrollLoop(Loop *L, UnrollLoopOptions ULO, LoopInfo *LI,
-     BasicBlock *FirstExitingBlock = nullptr;
-     SmallVector<BasicBlock *> ExitingBlocks;
-   };
--  DenseMap<BasicBlock *, ExitInfo> ExitInfos;
-+  MapVector<BasicBlock *, ExitInfo> ExitInfos;
-   SmallVector<BasicBlock *, 4> ExitingBlocks;
-   L->getExitingBlocks(ExitingBlocks);
-   for (auto *ExitingBlock : ExitingBlocks) {
diff --git a/meta/recipes-devtools/clang/common-clang.inc b/meta/recipes-devtools/clang/common-clang.inc
index 9018094419<tel:(901)%20809-4419>..5d571e5fce 100644
--- a/meta/recipes-devtools/clang/common-clang.inc
+++ b/meta/recipes-devtools/clang/common-clang.inc
@@ -3,9 +3,9 @@ LLVM_DIR = "llvm${LLVM_RELEASE}"

 LLVM_HTTP ?= "https://github.com/llvm"

-MAJOR_VER = "22"
+MAJOR_VER = "23"
 MINOR_VER = "1"
-PATCH_VER = "8"
+PATCH_VER = "0"
 # could be 'rcX' or 'git' or empty ( for release )
 VER_SUFFIX = ""

diff --git a/meta/recipes-devtools/clang/common.inc b/meta/recipes-devtools/clang/common.inc
index e1e03872cd..0ca6951ff4 100644
--- a/meta/recipes-devtools/clang/common.inc
+++ b/meta/recipes-devtools/clang/common.inc
@@ -17,51 +17,45 @@ BASEURI ?= "${LLVM_HTTP}/llvm-project/releases/download/llvmorg-${PV}${VER_SUFFI
 UPSTREAM_CHECK_URI = "${LLVM_HTTP}/llvm-project/releases/"
 UPSTREAM_CHECK_REGEX = "releases/tag/llvmorg-?(?P<pver>\d+(\.\d+)+)"
 SOURCEDIR ?= "llvm-project-${PV}${VER_SUFFIX}.src"
-SRC_URI[sha256sum] = "922f1817a0df7b1489272d18134ee0087a8b068828f87ac63b9861b1a9965888"
+SRC_URI[sha256sum] = "ab1f0e3ec52448c33e8782eaf0422504b87c7b016b22514653ee0d8fcee479ff"

 SRC_URI = "\
     ${BASEURI} \
-    file://0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch \
-    file://0002-compiler-rt-support-a-new-embedded-linux-target.patch \
-    file://0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch \
-    file://0004-llvm-allow-env-override-of-exe-and-libdir-path.patch \
-    file://0005-clang-driver-Check-sysroot-for-ldso-path.patch \
-    file://0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch \
-    file://0007-clang-Prepend-trailing-to-sysroot.patch \
-    file://0009-clang-Define-releative-gcc-installation-dir.patch \
-    file://0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch \
-    file://0011-Check-for-atomic-double-intrinsics.patch \
-    file://0012-cmake-Fix-configure-for-packages-using-find_package.patch \
-    file://0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch \
-    file://0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch \
-    file://0015-clang-Use-python3-in-python-scripts.patch \
-    file://0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch \
-    file://0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch \
-    file://0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch \
-    file://0019-libunwind-Added-unw_backtrace-method.patch \
-    file://0020-lldb-Link-with-libatomic-on-x86.patch \
-    file://0021-compiler-rt-Enable-__int128-for-ppc32.patch \
-    file://0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch \
-    file://0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch \
-    file://0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch \
-    file://0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch \
-    file://0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch \
-    file://0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch \
-    file://0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch \
-    file://0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch \
-    file://0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch \
-    file://0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch \
-    file://0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch \
-    file://0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch \
-    file://0035-Prevent-revisiting-block-when-searching-for-noreturn.patch \
-    file://0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch \
-    file://0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch \
-    file://0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch \
-    file://0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch \
-    file://0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch \
-    file://0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch \
-    file://0042-guard-clang-tools-extra-test.patch \
-    file://0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch \
+    file://0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch \
+    file://0002-llvm-allow-env-override-of-exe-and-libdir-path.patch \
+    file://0003-clang-driver-Check-sysroot-for-ldso-path.patch \
+    file://0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch \
+    file://0005-clang-Prepend-trailing-to-sysroot.patch \
+    file://0006-clang-Define-releative-gcc-installation-dir.patch \
+    file://0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch \
+    file://0008-Check-for-atomic-double-intrinsics.patch \
+    file://0009-cmake-Fix-configure-for-packages-using-find_package.patch \
+    file://0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch \
+    file://0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch \
+    file://0012-clang-Use-python3-in-python-scripts.patch \
+    file://0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch \
+    file://0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch \
+    file://0015-libunwind-Added-unw_backtrace-method.patch \
+    file://0016-lldb-Link-with-libatomic-on-x86.patch \
+    file://0017-compiler-rt-Enable-__int128-for-ppc32.patch \
+    file://0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch \
+    file://0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch \
+    file://0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch \
+    file://0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch \
+    file://0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch \
+    file://0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch \
+    file://0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch \
+    file://0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch \
+    file://0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch \
+    file://0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch \
+    file://0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch \
+    file://0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch \
+    file://0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch \
+    file://0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch \
+    file://0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch \
+    file://0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch \
+    file://0034-guard-clang-tools-extra-test.patch \
+    file://0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch \
 "
 # Fallback to no-PIE if not set
 GCCPIE ??= ""
--
2.43.0





-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#244696): https://lists.openembedded.org/g/openembedded-core/message/244696
Mute This Topic: https://lists.openembedded.org/mt/120998123/8968818
Group Owner: openembedded-core+owner@lists.openembedded.org<mailto:openembedded-core+owner@lists.openembedded.org>
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com<mailto:SunilKumar.Dora@windriver.com>]
-=-=-=-=-=-=-=-=-=-=-=-




[-- Attachment #2: Type: text/html, Size: 192630 bytes --]

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0
  2026-08-30 19:43   ` Khem Raj
@ 2026-09-01  4:07     ` Dora, Sunil Kumar
  0 siblings, 0 replies; 30+ messages in thread
From: Dora, Sunil Kumar @ 2026-09-01  4:07 UTC (permalink / raw)
  To: raj.khem@gmail.com
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 3535 bytes --]

On 8/31/2026 1:13 AM, Khem Raj via lists.openembedded.org wrote:
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.


On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>> wrote:
From: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>

Each release branch of the translator only builds against the
matching LLVM major. Move to the llvm_release_230 branch, pinned
at the v23.1.0 tag.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>
---
 ...translator_22.1.5.bb<http://translator_22.1.5.bb> => spirv-llvm-translator_23.1.0.bb<http://spirv-llvm-translator_23.1.0.bb>} | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
 rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb<http://spirv-llvm-translator_22.1.5.bb> => spirv-llvm-translator_23.1.0.bb<http://spirv-llvm-translator_23.1.0.bb>} (87%)

diff --git a/meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb<http://spirv-llvm-translator_22.1.5.bb> b/meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb<http://spirv-llvm-translator_23.1.0.bb>
similarity index 87%
rename from meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb<http://spirv-llvm-translator_22.1.5.bb>
rename to meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb<http://spirv-llvm-translator_23.1.0.bb>
index 1f80c6a27f..fd1dd9cfae 100644
--- a/meta/recipes-graphics/spir/spirv-llvm-translator_22.1.5.bb<http://spirv-llvm-translator_22.1.5.bb>
+++ b/meta/recipes-graphics/spir/spirv-llvm-translator_23.1.0.bb<http://spirv-llvm-translator_23.1.0.bb>
@@ -5,8 +5,8 @@ LICENSE = "NCSA"
 LIC_FILES_CHKSUM = "file://LICENSE.TXT;md5=47e311aa9caedd1b3abf098bd7814d1d"<file://LICENSE.TXT;md5=47e311aa9caedd1b3abf098bd7814d1d>

 # pattern: llvm_branch_200, currently there are no minor releases, so, no llvm_branch_201

  the header comment about the branch naming pattern still references the 200-era example and could be refreshed while you're here
Will refresh it in v2.

Thanks,
Sunil Dora

-SPIRV_BRANCH = "llvm_release_220"
-SRCREV = "27afcfe385cf542197dfde8c658e1f5ff53fc2fc"
+SPIRV_BRANCH = "llvm_release_230"
+SRCREV = "19a29d4376ab470909ba43ca014ae668fb1156c9"
 SRC_URI = " \
     git://github.com/KhronosGroup/SPIRV-LLVM-Translator;protocol=https;branch=${SPIRV_BRANCH};tag=v${PV}<http://github.com/KhronosGroup/SPIRV-LLVM-Translator;protocol=https;branch=$%7BSPIRV_BRANCH%7D;tag=v$%7BPV%7D> \
 "
@@ -18,7 +18,7 @@ DEPENDS = "llvm spirv-tools spirv-headers"
 inherit cmake pkgconfig lib_package

 EXTRA_OECMAKE = "\
-    -DBASE_LLVM_VERSION=22.1.0 \
+    -DBASE_LLVM_VERSION=23.1.0 \
     -DCMAKE_SKIP_BUILD_RPATH=ON \
     -DBUILD_SHARED_LIBS=ON \
     -DLLVM_EXTERNAL_SPIRV_HEADERS_SOURCE_DIR=${STAGING_INCDIR}/.. \
--
2.43.0





-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#244693): https://lists.openembedded.org/g/openembedded-core/message/244693
Mute This Topic: https://lists.openembedded.org/mt/120998126/8968818
Group Owner: openembedded-core+owner@lists.openembedded.org<mailto:openembedded-core+owner@lists.openembedded.org>
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com<mailto:SunilKumar.Dora@windriver.com>]
-=-=-=-=-=-=-=-=-=-=-=-




[-- Attachment #2: Type: text/html, Size: 6872 bytes --]

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 03/11] openmp: Build via the LLVM runtimes entry point
  2026-08-30 19:45   ` Khem Raj
@ 2026-09-01  4:33     ` Dora, Sunil Kumar
  2026-09-03  1:11       ` Khem Raj
  0 siblings, 1 reply; 30+ messages in thread
From: Dora, Sunil Kumar @ 2026-09-01  4:33 UTC (permalink / raw)
  To: raj.khem@gmail.com
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 4020 bytes --]

On 8/31/2026 1:15 AM, Khem Raj via lists.openembedded.org wrote:
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.


On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>> wrote:
From: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>

LLVM 23 removed the standalone build mode for openmp, so do_configure
fails with

  The legacy standalone build mode has been removed

Configure it through the runtimes build with LLVM_ENABLE_RUNTIMES=openmp,
the same way libcxx is built.

The runtimes build reads LLVM_LIBDIR_SUFFIX; nothing in LLVM 23 reads
OPENMP_LIBDIR_SUFFIX any more, so pass the standard variable like the
other clang-family recipes do. Without it openmp installs into lib/
while a multilib configuration packages lib64/, and do_package fails
with "installed but not shipped" for libomp.so, libarcher.so,
libompd.so and the cmake files.

Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>
---
 meta/recipes-devtools/clang/openmp_git.bb<http://openmp_git.bb> | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-devtools/clang/openmp_git.bb<http://openmp_git.bb> b/meta/recipes-devtools/clang/openmp_git.bb<http://openmp_git.bb>
index 2ba83d48c6..90d4911623 100644
--- a/meta/recipes-devtools/clang/openmp_git.bb<http://openmp_git.bb>
+++ b/meta/recipes-devtools/clang/openmp_git.bb<http://openmp_git.bb>
@@ -18,10 +18,11 @@ inherit cmake pkgconfig python3targetconfig
 DEPENDS += "elfutils libffi clang"

 EXTRA_OECMAKE += "-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-                  -DOPENMP_LIBDIR_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \
+                  -DLLVM_ENABLE_RUNTIMES=openmp \
+                  -DLLVM_LIBDIR_SUFFIX=${LLVM_LIBDIR_SUFFIX} \



The recipe keeps PACKAGECONFIG ?= "ompt-tools offloading-plugin" — under the runtimes entry point, does offloading-plugin still do anything, or would it now need offload added to LLVM_ENABLE_RUNTIMES?
It doesn't do anything for the build, and it didn't with the old entry point either. It passes no cmake flags and the build depends
are already in DEPENDS. So the only thing it really adds is the libelf/libffi RDEPENDS. Our libomp.so links only libc.
The plugins that needed libffi/libelf moved out of openmp/ into offload/ back in LLVM 19, so nothing here builds them.
The openmp-libomptarget package is empty, no ipk gets written.

I only checked oe-core, other layers may still use this option, you know that history better than me.

OPENMP_ENABLE_LIBOMPTARGET still works though. It adds some hooks in libomp that look up libomptarget functions with dlsym at runtime.
Default is ON on 64-bit, the recipe doesn't touch it, and it is the same with both entry points.

To actually build the plugins we would need LLVM_ENABLE_RUNTIMES="openmp;offload".
That is a new library and new packaging, so I did not want to mix it into the upgrade.

As a follow-up I can keep the PACKAGECONFIG as is, drop it with the empty package, or add offload as a new option.
Which one do you prefer?

Thanks,
Sunil Dora


               "

-OECMAKE_SOURCEPATH = "${S}/openmp"
+OECMAKE_SOURCEPATH = "${S}/runtimes"

 PACKAGECONFIG ?= "ompt-tools offloading-plugin"

--
2.43.0





-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#244694): https://lists.openembedded.org/g/openembedded-core/message/244694
Mute This Topic: https://lists.openembedded.org/mt/120998125/8968818
Group Owner: openembedded-core+owner@lists.openembedded.org<mailto:openembedded-core+owner@lists.openembedded.org>
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com<mailto:SunilKumar.Dora@windriver.com>]
-=-=-=-=-=-=-=-=-=-=-=-




[-- Attachment #2: Type: text/html, Size: 7527 bytes --]

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
  2026-08-30 19:53 ` [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 Khem Raj
@ 2026-09-01  4:59   ` Dora, Sunil Kumar
  2026-09-03  1:10     ` Khem Raj
  0 siblings, 1 reply; 30+ messages in thread
From: Dora, Sunil Kumar @ 2026-09-01  4:59 UTC (permalink / raw)
  To: raj.khem@gmail.com
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 15022 bytes --]

On 8/31/2026 1:23 AM, Khem Raj via lists.openembedded.org wrote:
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.
Looks pretty good to me. I have few feedback comments, not a merge blocker but good to consider for future ease of porting.
Thanks Khem.

Quick update on the upstream side since the series went out.

The clang half of the ssp_nonshared patch (0004 in the stack) was merged into llvm main yesterday, commit fd974c429301<https://github.com/llvm/llvm-project/commit/fd974c4293015388337e2f66f817a23e5873389f>, reviewed by
MaskRay (Original PR #219828<https://github.com/llvm/llvm-project/pull/219828> ). A backport to release/23.x is open as PR #220136<https://github.com/llvm/llvm-project/pull/220136>.
If that lands I will flip 0004 to Upstream-Status: Backport, and at the next upgrade the patch goes away entirely.

The gcc half is on gcc-patches<https://gcc.gnu.org/pipermail/gcc-patches/2026-August/729351.html> as v2 with bugzilla PR 127138<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=127138>. Sam James mentioned Gentoo has carried the same fix downstream for years.

Thanks,
Sunil Dora

On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>> wrote:
From: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>

This upgrades clang/llvm from 22.1.8 to 23.1.0 and fixes the fallout
found while testing the result.

The carried LLVM patch stack goes from 41 to 35: seven dropped
because 23.1.0 already contains the fix or the code they patched no
longer exists, three reworked for LLVM 23, and one added for a 32-bit
x86 build break, already merged in llvm-project.

Please apply with git am --keep-cr: patch 8 fixes an ovmf file that
uses CRLF line endings, and plain git am corrupts the patch.

I have also reported the underlying bugs upstream:
  llvm float16 fix, merged:
    https://github.com/llvm/llvm-project/pull/219675
  ovmf fix, sent to edk2:
    https://github.com/tianocore/edk2/pull/13038
  pango warning, the root cause is in GLib, reported to both:
    https://gitlab.gnome.org/GNOME/glib/-/issues/4038
    https://gitlab.gnome.org/GNOME/pango/-/issues/900
  vulkan-samples warning, which is a real bug in their code:
    https://github.com/KhronosGroup/Vulkan-Samples/issues/1570

Tested: oe-selftest clang suites on qemuarm, qemuarm64, qemux86,
qemux86-64 and qemuriscv64 on the autobuilder, musl images on qemux86
and qemuarm64, a qemux86 world build with TOOLCHAIN=clang, 32-bit
multilib, and core-image-minimal testimage runs.

Deepesh Varatharajan (2):
  rust: Fix build and oe-selftest failures with LLVM 23
  clang/llvm: Ignore tests fail with clang/llvm 23 upgrade

Sunil Dora (9):
  clang/llvm: Upgrade to 23.1.0 release
  spirv-llvm-translator: Upgrade to 23.1.0
  openmp: Build via the LLVM runtimes entry point
  rust: Do not pass the removed x86 amx-tf32 feature to LLVM 23
  clang: Disable clangd's decision-forest completion model on powerpc
  pango: Don't turn clang 23's -Wunused-but-set-global into an error
  ovmf: Fix memcpy alias prototype for clang 23
  vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error
  gettext: Export a fully-flagged Objective-C compiler

 meta/conf/distro/include/maintainers.inc      |   2 +-
 meta/lib/oeqa/selftest/cases/clang.py         |  10 +
 meta/lib/oeqa/selftest/cases/rust.py          |   1 +
 ...t-env.in-do-not-add-C-CXX-parameters.patch |  17 +-
 meta/recipes-core/gettext/gettext_1.0.bb<http://gettext_1.0.bb>      |   5 +
 ...sicLib-fix-memcpy-alias-prototype-fo.patch |  35 +
 meta/recipes-core/ovmf/ovmf_git.bb<http://ovmf_git.bb>            |   1 +
 ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
 ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 --
 ...-support-a-new-embedded-linux-target.patch | 309 --------
 ...env-override-of-exe-and-libdir-path.patch} |   4 +-
 ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
 ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
 ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
 ...fine-releative-gcc-installation-dir.patch} |  10 +-
 ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
 ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
 ...ure-for-packages-using-find_package.patch} |  20 +-
 ...e-dir-location-for-cross-toolchains.patch} |   4 +-
 ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
 ...clang-Use-python3-in-python-scripts.patch} |   6 +-
 ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +-
 ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
 ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
 ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
 ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 --
 ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
 ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
 ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
 ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
 ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 +-
 ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
 ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
 ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
 ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
 ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
 ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
 ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
 ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
 ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
 ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
 ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
 ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
 ...> 0034-guard-clang-tools-extra-test.patch} |  47 +-
 ...ng-block-when-searching-for-noreturn.patch |  41 --
 ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 +
 ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 --------
 ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 -
 ...te-exit-fold-candidates-in-determini.patch |  71 --
 meta/recipes-devtools/clang/clang_git.bb<http://clang_git.bb>      |   4 +
 meta/recipes-devtools/clang/common-clang.inc  |   4 +-
 meta/recipes-devtools/clang/common.inc        |  78 +--
 meta/recipes-devtools/clang/openmp_git.bb<http://openmp_git.bb>     |   5 +-
 ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
 ...llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch |  38 +
 meta/recipes-devtools/rust/rust-source.inc    |   2 +
 ...ror-on-clang-s-unused-but-set-global.patch |  28 +
 meta/recipes-graphics/pango/pango_1.58.0.bb<http://pango_1.58.0.bb>   |   1 +
 ...1.5.bb<http://1.5.bb> => spirv-llvm-translator_23.1.0.bb<http://spirv-llvm-translator_23.1.0.bb>} |   6 +-
 .../vulkan/vulkan-samples_git.bb<http://vulkan-samples_git.bb>              |   4 +-
 60 files changed, 1109 insertions(+), 1113 deletions(-)
 create mode 100644 meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch
 rename meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
 rename meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
 rename meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
 rename meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
 rename meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
 rename meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
 rename meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
 rename meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
 rename meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
 rename meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
 rename meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
 rename meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
 rename meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
 rename meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
 rename meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
 rename meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
 rename meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
 rename meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
 rename meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch => 0034-guard-clang-tools-extra-test.patch} (83%)
 delete mode 100644 meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
 create mode 100644 meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
 delete mode 100644 meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
 create mode 100644 meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
 create mode 100644 meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch
 create mode 100644 meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
 rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb<http://spirv-llvm-translator_22.1.5.bb> => spirv-llvm-translator_23.1.0.bb<http://spirv-llvm-translator_23.1.0.bb>} (87%)

--
2.43.0





-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#244697): https://lists.openembedded.org/g/openembedded-core/message/244697
Mute This Topic: https://lists.openembedded.org/mt/120998127/8968818
Group Owner: openembedded-core+owner@lists.openembedded.org<mailto:openembedded-core+owner@lists.openembedded.org>
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com<mailto:SunilKumar.Dora@windriver.com>]
-=-=-=-=-=-=-=-=-=-=-=-




[-- Attachment #2: Type: text/html, Size: 20515 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23
  2026-08-30 19:47   ` Khem Raj
@ 2026-09-01  5:17     ` Dora, Sunil Kumar
  2026-09-03  1:08       ` Khem Raj
  0 siblings, 1 reply; 30+ messages in thread
From: Dora, Sunil Kumar @ 2026-09-01  5:17 UTC (permalink / raw)
  To: raj.khem@gmail.com
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 34911 bytes --]

On 8/31/2026 1:17 AM, Khem Raj via lists.openembedded.org wrote:
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.
I wonder if each backport should have been a patch of its own. It would make it easy to maintain of some of them get backported to later versions of rust.
I checked with Deepesh. These all exist for the same llvm 23 bump, mostly test guarding plus the one AssignGUID wrapper fix, and they become redundant
together once we move to a rust that supports LLVM 23. So one patch keeps it simple here. For real compiler or library backports we agree
separate patches make life easier and we will do that going forward. Ok to keep this one as is?

Thanks,
Sunil Dora

On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>> wrote:
From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>

Backport upstream Rust commits to address build and oe-selftest
failures introduced by the LLVM 23 upgrade.

New patch:
0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
The backported changes update LLVM 23 compatibility in the Rust LLVM
wrapper and adjust affected LLVM codegen tests.

Selftest Changes:
Exclude the following Windows-specific test from oe-selftest,
as it is not relevant.
tests/assembly-llvm/x86_64-windows-float-abi.rs

Excluded tests:
+---------+---------+---------+
| Before  |  After  | Skipped |
+---------+---------+---------+
|   43    |   44    |   +1    |
+---------+---------+---------+

Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>
Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com<mailto:sunilkumar.dora@windriver.com>>
---
 meta/lib/oeqa/selftest/cases/rust.py          |   1 +
 ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
 meta/recipes-devtools/rust/rust-source.inc    |   1 +
 3 files changed, 663 insertions(+)
 create mode 100644 meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch

diff --git a/meta/lib/oeqa/selftest/cases/rust.py b/meta/lib/oeqa/selftest/cases/rust.py
index fa8a8c1e7c..645b5d5fbf 100644
--- a/meta/lib/oeqa/selftest/cases/rust.py
+++ b/meta/lib/oeqa/selftest/cases/rust.py
@@ -83,6 +83,7 @@ class RustSelfTestSystemEmulated(OESelftestTestCase, OEPTestResultTestCase):
                             'src/tools/tidy',
                             'tests/assembly-llvm/asm/aarch64-outline-atomics.rs',
                             'tests/assembly-llvm/c-variadic/arm.rs',
+                            'tests/assembly-llvm/x86_64-windows-float-abi.rs',
                             'tests/codegen-llvm/thread-local.rs',
                             'tests/mir-opt/',
                             'tests/run-make',
diff --git a/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
new file mode 100644
index 0000000000..1e1bf089f1
--- /dev/null
+++ b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
@@ -0,0 +1,661 @@
+Backport commits that fix build and oe-selftest failures seen with llvm 23
+
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/b8d3a4ac9cfeb81d1e929fe6eab0af4b77ba3bb4]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/d4a24cd6e18b98326429d8c7e7bbb269da14a5aa]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/20ac2125a2142c9bde53ca06d9b3cfb6941fd437]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/2d18054569d1169bfae7ce21e5c7111f32f16774]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/e2159107f6ebc615ba6a92960d65528baf90cd35]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/283a60b64339d611b76a4ed2f9286f417b269b2f]
+Upstream-Status: Backport [https://github.com/rust-lang/rust/commit/61d9ba28a99f073fbeb19dbb552ddf343aef62f0]
+
+Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com<mailto:Deepesh.Varatharajan@windriver.com>>
+
+diff --git a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
+index fe5b8edce4a..e4807f10805 100644
+--- a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
++++ b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
+@@ -49,6 +49,9 @@
+ #include "llvm/Transforms/Instrumentation/RealtimeSanitizer.h"
+ #include "llvm/Transforms/Instrumentation/ThreadSanitizer.h"
+ #include "llvm/Transforms/Scalar/AnnotationRemarks.h"
++#if LLVM_VERSION_GE(23, 0)
++#include "llvm/Transforms/Utils/AssignGUID.h"
++#endif
+ #include "llvm/Transforms/Utils/CanonicalizeAliases.h"
+ #include "llvm/Transforms/Utils/FunctionImportUtils.h"
+ #include "llvm/Transforms/Utils/NameAnonGlobals.h"
+@@ -925,6 +928,9 @@
+   if (NeedThinLTOBufferPasses) {
+     MPM.addPass(CanonicalizeAliasesPass());
+     MPM.addPass(NameAnonGlobalPass());
++#if LLVM_VERSION_GE(23, 0)
++    MPM.addPass(AssignGUIDPass());
++#endif
+   }
+   // For `-Copt-level=0`, and the pre-link fat/thin LTO stages.
+   if (ThinLTOBufferRef && *ThinLTOBufferRef == nullptr) {
+@@ -1464,6 +1470,9 @@
+         PB.registerLoopAnalyses(LAM);
+         PB.crossRegisterProxies(LAM, FAM, CGAM, MAM);
+         ModulePassManager MPM;
++#if LLVM_VERSION_GE(23, 0)
++        MPM.addPass(AssignGUIDPass());
++#endif
+         MPM.addPass(ThinLTOBitcodeWriterPass(OS, nullptr));
+         MPM.run(*unwrap(M), MAM);
+       } else {
+diff --git a/tests/codegen-llvm/bpf-allows-unaligned.rs b/tests/codegen-llvm/bpf-allows-unaligned.rs
+index c7a70d5b2e5..7e95a56d984 100644
+--- a/tests/codegen-llvm/bpf-allows-unaligned.rs
++++ b/tests/codegen-llvm/bpf-allows-unaligned.rs
+@@ -5,7 +5,7 @@
+
+ #[no_mangle]
+ #[target_feature(enable = "allows-misaligned-mem-access")]
+-// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg) unnamed_addr #0 {
++// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg) unnamed_addr #0
+ pub unsafe fn foo(arg: u8) -> u8 {
+     arg
+ }
+diff --git a/tests/codegen-llvm/branch-protection.rs b/tests/codegen-llvm/branch-protection.rs
+index ed1cb2cd137..11847c256d6 100644
+--- a/tests/codegen-llvm/branch-protection.rs
++++ b/tests/codegen-llvm/branch-protection.rs
+@@ -22,7 +22,7 @@
+ use minicore::*;
+
+ // A basic test function.
+-// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]] {
++// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]]
+ #[no_mangle]
+ pub fn test() {}
+
+diff --git a/tests/codegen-llvm/frame-pointer-cli-control.rs b/tests/codegen-llvm/frame-pointer-cli-control.rs
+index 911a5f03cbc..79cdfc70f1a 100644
+--- a/tests/codegen-llvm/frame-pointer-cli-control.rs
++++ b/tests/codegen-llvm/frame-pointer-cli-control.rs
+@@ -45,7 +45,7 @@
+
+ extern crate minicore;
+
+-// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
++// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
+ #[no_mangle]
+ pub fn peach(x: u32) -> u32 {
+     x
+diff --git a/tests/codegen-llvm/frame-pointer.rs b/tests/codegen-llvm/frame-pointer.rs
+index 1d0dd762826..a52d95a2386 100644
+--- a/tests/codegen-llvm/frame-pointer.rs
++++ b/tests/codegen-llvm/frame-pointer.rs
+@@ -18,7 +18,7 @@
+ extern crate minicore;
+ use minicore::*;
+
+-// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
++// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
+ #[no_mangle]
+ pub fn peach(x: u32) -> u32 {
+     x
+diff --git a/tests/codegen-llvm/gpu-convergent.rs b/tests/codegen-llvm/gpu-convergent.rs
+index bb9271ab699..376d65a3d4a 100644
+--- a/tests/codegen-llvm/gpu-convergent.rs
++++ b/tests/codegen-llvm/gpu-convergent.rs
+@@ -17,7 +17,7 @@
+     fn ext();
+ }
+
+-// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr #[[ATTR:[0-9]+]] {
++// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr #[[ATTR:[0-9]+]]
+ // CHECK: declare void @ext() unnamed_addr #[[ATTR]]
+ // CHECK: attributes #[[ATTR]] = {{.*}} convergent
+ #[no_mangle]
+diff --git a/tests/codegen-llvm/instrument-coverage/testprog.rs b/tests/codegen-llvm/instrument-coverage/testprog.rs
+index ef61ede6de8..67c49c438f9 100644
+--- a/tests/codegen-llvm/instrument-coverage/testprog.rs
++++ b/tests/codegen-llvm/instrument-coverage/testprog.rs
+@@ -101,7 +101,7 @@ fn main() {
+ // CHECK-SAME:   @__llvm_prf_nm
+ // CHECK-SAME:   section "llvm.metadata"
+
+-// CHECK:        define internal { {{.*}} } @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}} {
++// CHECK:        define internal { {{.*}} } @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}}
+ // CHECK-NEXT:   start:
+ // CHECK-NOT:    define internal
+ // CHECK:        atomicrmw add ptr
+@@ -109,7 +109,7 @@ fn main() {
+
+ // CHECK:        declare void @llvm.instrprof.increment(ptr, i64, i32, i32) #[[LLVM_INSTRPROF_INCREMENT_ATTR:[0-9]+]]
+
+-// WIN:          define linkonce_odr hidden i32 @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]] comdat {{.*}}{
++// WIN:          define linkonce_odr hidden i32 @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]] comdat {{.*}}
+ // WIN-NEXT:     %1 = load i32, ptr @__llvm_profile_runtime
+ // WIN-NEXT:     ret i32 %1
+ // WIN-NEXT:     }
+diff --git a/tests/codegen-llvm/link_section.rs b/tests/codegen-llvm/link_section.rs
+index f196ea86c44..61bde683c0a 100644
+--- a/tests/codegen-llvm/link_section.rs
++++ b/tests/codegen-llvm/link_section.rs
+@@ -29,7 +29,7 @@ pub enum E {
+ #[link_section = "__TEST,three"]
+ pub static VAR3: E = E::B(1.);
+
+-// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section "__TEST,four" {
++// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section "__TEST,four"
+ #[no_mangle]
+ #[link_section = "__TEST,four"]
+ pub fn fn1() {}
+diff --git a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
+index 7639ce7b104..5b1aa97ab33 100644
+--- a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
++++ b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
+@@ -7,21 +7,21 @@
+
+ pub fn foo(f: fn(i32) -> i32, arg: i32) -> i32 {
+     // CHECK-LABEL: define{{.*}}foo
+-    // CHECK-SAME:  {{.*}}![[TYPE1:[0-9]+]]
++    // CHECK-SAME:  {{.*}}!type ![[TYPE1:[0-9]+]]
+     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata !"_ZTSFu3i32S_E.normalized.generalized")
+     f(arg)
+ }
+
+ pub fn bar(f: fn(i32, i32) -> i32, arg1: i32, arg2: i32) -> i32 {
+     // CHECK-LABEL: define{{.*}}bar
+-    // CHECK-SAME:  {{.*}}![[TYPE2:[0-9]+]]
++    // CHECK-SAME:  {{.*}}!type ![[TYPE2:[0-9]+]]
+     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata !"_ZTSFu3i32S_S_E.normalized.generalized")
+     f(arg1, arg2)
+ }
+
+ pub fn baz(f: fn(i32, i32, i32) -> i32, arg1: i32, arg2: i32, arg3: i32) -> i32 {
+     // CHECK-LABEL: define{{.*}}baz
+-    // CHECK-SAME:  {{.*}}![[TYPE3:[0-9]+]]
++    // CHECK-SAME:  {{.*}}!type ![[TYPE3:[0-9]+]]
+     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata !"_ZTSFu3i32S_S_S_E.normalized.generalized")
+     f(arg1, arg2, arg3)
+ }
+diff --git a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
+index 35317b0dd39..3df2d569f9a 100644
+--- a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
++++ b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
+@@ -72,7 +72,7 @@ pub unsafe fn some_non_zero_from_atomic_get() -> Option<NonZeroUsize> {
+ ///
+ /// The way we check that the LLVM IR is correct is by making sure that neither
+ /// `panic` nor `unreachable` is part of the LLVM IR:
+-// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2() {{.*}} {
++// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2() {{.*}}
+ // CHECK-NOT: panic
+ // CHECK-NOT: unreachable
+ #[no_mangle]
+diff --git a/tests/codegen-llvm/target-feature-negative-implication.rs b/tests/codegen-llvm/target-feature-negative-implication.rs
+index a9cdca42839..376599738e5 100644
+--- a/tests/codegen-llvm/target-feature-negative-implication.rs
++++ b/tests/codegen-llvm/target-feature-negative-implication.rs
+@@ -13,7 +13,7 @@
+ #[no_mangle]
+ pub unsafe fn banana() {
+     // CHECK-LABEL: @banana()
+-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
+ }
+
+ // CHECK: attributes [[BANANAATTRS]]
+diff --git a/tests/codegen-llvm/target-feature-overrides.rs b/tests/codegen-llvm/target-feature-overrides.rs
+index 2adc8ee6f53..3bf05c7977e 100644
+--- a/tests/codegen-llvm/target-feature-overrides.rs
++++ b/tests/codegen-llvm/target-feature-overrides.rs
+@@ -23,7 +23,7 @@
+ #[no_mangle]
+ pub unsafe fn apple() -> u32 {
+     // CHECK-LABEL: @apple()
+-    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]] {
++    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]]
+     // CHECK: {{.*}}call{{.*}}@peach
+     peach()
+ }
+@@ -32,7 +32,7 @@ pub unsafe fn apple() -> u32 {
+ #[no_mangle]
+ pub unsafe fn banana() -> u32 {
+     // CHECK-LABEL: @banana()
+-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
+     // COMPAT: {{.*}}call{{.*}}@peach
+     // INCOMPAT: {{.*}}call{{.*}}@apple
+     apple() // Compatible for inline in COMPAT revision and can't be inlined in INCOMPAT
+diff --git a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
+index ecace722e0d..279780e3a7a 100644
+--- a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `aapcs-unwind` extern functions. `aapcs-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "aapcs" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "aapcs-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
+index 46c08b5fc4f..1b3312839e3 100644
+--- a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
+@@ -7,11 +7,11 @@
+
+ #![crate_type = "lib"]
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "C" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "C-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
+index 8e643d6ce49..6f4eafb353c 100644
+--- a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
+@@ -7,11 +7,11 @@
+
+ #![crate_type = "lib"]
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "cdecl" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "cdecl-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
+index 7df46813ed1..51c6fd15b9c 100644
+--- a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `fastcall-unwind` extern functions. `fastcall-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "fastcall" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "fastcall-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
+index cc06ee12549..b5fcea52b4d 100644
+--- a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // extern functions. `stdcall-unwind` functions MUST NOT have this attribute. We disable
+ // optimizations above to prevent LLVM from inferring the attribute.
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "stdcall" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "stdcall-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
+index 5f910248346..15fce95fe28 100644
+--- a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
+@@ -7,11 +7,11 @@
+
+ #![crate_type = "lib"]
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "system" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "system-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
+index 69bfaf80b4b..1293e7c0a5f 100644
+--- a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `sysv64-unwind` extern functions. `sysv64-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "sysv64" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "sysv64-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
+index 05f6b8b70e1..a9b6c34ee58 100644
+--- a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `thiscall-unwind` extern functions. `thiscall-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "thiscall" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "thiscall-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
+index d001a16b32a..8cedb55ae1d 100644
+--- a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `vectorcall-unwind` extern functions. `vectorcall-unwind` functions MUST NOT have this attribute.
+ // We disable optimizations above to prevent LLVM from inferring the attribute.
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "vectorcall" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "vectorcall-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
+index 257f00b54e4..2a3ad330406 100644
+--- a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
++++ b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
+@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
+ // `win64-unwind` extern functions. `win64-unwind` functions MUST NOT have this attribute. We
+ // disable optimizations above to prevent LLVM from inferring the attribute.
+
+-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
+ #[no_mangle]
+ pub extern "win64" fn rust_item_that_cannot_unwind() {}
+
+-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
+ #[no_mangle]
+ pub extern "win64-unwind" fn rust_item_that_can_unwind() {}
+
+diff --git a/tests/assembly-llvm/slice-is_ascii.rs b/tests/assembly-llvm/slice-is_ascii.rs
+index e53cd5160cf..6d660e78147 100644
+--- a/tests/assembly-llvm/slice-is_ascii.rs
++++ b/tests/assembly-llvm/slice-is_ascii.rs
+@@ -6,6 +6,11 @@
+ //@ only-x86_64
+ //@ ignore-sgx
+
++// No longer optimizes as desired, tracked at:
++// https://github.com/rust-lang/rust/issues/154141
++// https://github.com/llvm/llvm-project/issues/209216
++//@ max-llvm-major-version: 22
++
+ #![feature(str_internals)]
+
+ // CHECK-LABEL: is_ascii_simple_demo:
+diff --git a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
+index 40d16886c6d..d3698fda5fe 100644
+--- a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
++++ b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
+@@ -1,12 +1,16 @@
+ // verify that simd mask reductions do not introduce additional bit shift operations
+ //@ add-minicore
+-//@ revisions: x86 aarch64
++//@ revisions: x86 aarch64-llvm22 aarch64
+ //@ [x86] compile-flags: --target=x86_64-unknown-linux-gnu -C llvm-args=-x86-asm-syntax=intel
+ // Set the base cpu explicitly, in case the default has been changed.
+ //@ [x86] compile-flags: -C target-cpu=x86-64
+ //@ [x86] needs-llvm-components: x86
++//@ [aarch64-llvm22] compile-flags: --target=aarch64-unknown-linux-gnu
++//@ [aarch64-llvm22] needs-llvm-components: aarch64
++//@ [aarch64-llvm22] max-llvm-major-version: 22
+ //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
+ //@ [aarch64] needs-llvm-components: aarch64
++//@ [aarch64] min-llvm-version: 23
+ //@ assembly-output: emit-asm
+ //@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
+
+@@ -33,12 +37,19 @@
+     // x86-NEXT: {{cmp ax, -1|cmp eax, 65535|xor eax, 65535}}
+     // x86-NEXT: sete al
+     //
++    // aarch64-llvm22-NOT: shl
++    // aarch64-llvm22: cmge v0.16b, v0.16b, #0
++    // aarch64-llvm22-DAG: mov [[REG1:[a-z0-9]+]], #1
++    // aarch64-llvm22-DAG: umaxv b0, v0.16b
++    // aarch64-llvm22-NEXT: fmov [[REG2:[a-z0-9]+]], s0
++    // aarch64-llvm22-NEXT: bic w0, [[REG1]], [[REG2]]
++    //
+     // aarch64-NOT: shl
+     // aarch64: cmge v0.16b, v0.16b, #0
+-    // aarch64-DAG: mov [[REG1:[a-z0-9]+]], #1
+-    // aarch64-DAG: umaxv b0, v0.16b
+-    // aarch64-NEXT: fmov [[REG2:[a-z0-9]+]], s0
+-    // aarch64-NEXT: bic w0, [[REG1]], [[REG2]]
++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
++    // aarch64-NEXT: cmp [[REG2]], #0
++    // aarch64-NEXT: cset w0, eq
+     simd_reduce_all(m)
+ }
+
+@@ -50,10 +61,17 @@
+     // x86-NEXT: test eax, eax
+     // x86-NEXT: setne al
+     //
++    // aarch64-llvm22-NOT: shl
++    // aarch64-llvm22: cmlt v0.16b, v0.16b, #0
++    // aarch64-llvm22-NEXT: umaxv b0, v0.16b
++    // aarch64-llvm22-NEXT: fmov [[REG:[a-z0-9]+]], s0
++    // aarch64-llvm22-NEXT: and w0, [[REG]], #0x1
++    //
+     // aarch64-NOT: shl
+     // aarch64: cmlt v0.16b, v0.16b, #0
+-    // aarch64-NEXT: umaxv b0, v0.16b
+-    // aarch64-NEXT: fmov [[REG:[a-z0-9]+]], s0
+-    // aarch64-NEXT: and w0, [[REG]], #0x1
++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
++    // aarch64-NEXT: cmp [[REG2]], #0
++    // aarch64-NEXT: cset w0, ne
+     simd_reduce_any(m)
+ }
+diff --git a/tests/codegen-llvm/asm/global_asm.rs b/tests/codegen-llvm/asm/global_asm.rs
+index 32075daa3cf..8c1c4a3b588 100644
+--- a/tests/codegen-llvm/asm/global_asm.rs
++++ b/tests/codegen-llvm/asm/global_asm.rs
+@@ -7,10 +7,10 @@
+
+ use std::arch::global_asm;
+
+-// CHECK-LABEL: foo
+ // CHECK: module asm
++// CHECK-LABEL: foo
+ // this regex will capture the correct unconditional branch inst.
+-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
++// CHECK: "{{[[:space:]]+}}jmp baz"
+ global_asm!(
+     r#"
+     .global foo
+diff --git a/tests/codegen-llvm/asm/global_asm_include.rs b/tests/codegen-llvm/asm/global_asm_include.rs
+index 98be9c3e333..cad9901336b 100644
+--- a/tests/codegen-llvm/asm/global_asm_include.rs
++++ b/tests/codegen-llvm/asm/global_asm_include.rs
+@@ -7,9 +7,9 @@
+
+ use std::arch::global_asm;
+
+-// CHECK-LABEL: foo
+ // CHECK: module asm
+-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
++// CHECK-LABEL: foo
++// CHECK: "{{[[:space:]]+}}jmp baz"
+ global_asm!(include_str!("foo.s"));
+
+ extern "C" {
+diff --git a/tests/codegen-llvm/asm/global_asm_x2.rs b/tests/codegen-llvm/asm/global_asm_x2.rs
+index 9e3a00f0680..8c6f38289de 100644
+--- a/tests/codegen-llvm/asm/global_asm_x2.rs
++++ b/tests/codegen-llvm/asm/global_asm_x2.rs
+@@ -8,12 +8,12 @@
+
+ use core::arch::global_asm;
+
+-// CHECK-LABEL: foo
+ // CHECK: module asm
+-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
++// CHECK-LABEL: foo
++// CHECK: "{{[[:space:]]+}}jmp baz"
+ // any other global_asm will be appended to this first block, so:
+ // CHECK-LABEL: bar
+-// CHECK: module asm "{{[[:space:]]+}}jmp quux"
++// CHECK: "{{[[:space:]]+}}jmp quux"
+ global_asm!(
+     r#"
+     .global foo
+diff --git a/tests/codegen-llvm/array-cmp.rs b/tests/codegen-llvm/array-cmp.rs
+index 0106b9c15c1..5b0a802f409 100644
+--- a/tests/codegen-llvm/array-cmp.rs
++++ b/tests/codegen-llvm/array-cmp.rs
+@@ -2,6 +2,9 @@
+
+ //@ compile-flags: -C opt-level=2
+ //@ needs-deterministic-layouts (checks depend on tuple layout)
++//@ revisions: LLVM22 LLVM23
++//@ [LLVM22] max-llvm-major-version: 22
++//@ [LLVM23] min-llvm-version: 23
+
+ #![crate_type = "lib"]
+
+@@ -66,7 +69,8 @@ pub fn compare() -> bool {
+     // CHECK-NEXT: br i1 %[[EQ01]], label %{{.+}}, label %[[EXIT_U]]
+
+     // CHECK: [[DONE]]:
+-    // CHECK: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [ %{{.+}}, %[[EXIT_U]] ], [ true, %[[L11]] ]
++    // LLVM22: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [ %{{.+}}, %[[EXIT_U]] ], [ true, %[[L11]] ]
++    // LLVM23: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_U]] ], [ %{{.+}}, %[[EXIT_S]] ], [ true, %[[L11]] ]
+     // CHECK: ret i1 %[[RET]]
+
+     a <= b
+diff --git a/tests/codegen-llvm/enum/enum-match.rs b/tests/codegen-llvm/enum/enum-match.rs
+index 6d8b97328f8..a0cba452e12 100644
+--- a/tests/codegen-llvm/enum/enum-match.rs
++++ b/tests/codegen-llvm/enum/enum-match.rs
+@@ -1,5 +1,8 @@
+ //@ compile-flags: -Copt-level=1
+ //@ only-64bit
++//@ revisions: LLVM22 LLVM23
++//@ [LLVM22] max-llvm-major-version: 22
++//@ [LLVM23] min-llvm-version: 23
+
+ #![crate_type = "lib"]
+ #![feature(core_intrinsics)]
+@@ -18,8 +21,9 @@ pub enum Enum0 {
+ // CHECK-LABEL: define{{( dso_local)?}} noundef{{( range\(i8 [0-9]+, [0-9]+\))?}} i8 @match0(i8{{.+}}%0)
+ // CHECK-NEXT: start:
+ // CHECK-NEXT: %[[IS_B:.+]] = icmp eq i8 %0, 2
+-// CHECK-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
+-// CHECK-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
++// LLVM22-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
++// LLVM22-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
++// LLVM23-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %0
+ // CHECK-NEXT: ret i8 %[[R]]
+ #[no_mangle]
+ pub fn match0(e: Enum0) -> u8 {
+diff --git a/tests/assembly-llvm/simd-bitmask.rs b/tests/assembly-llvm/simd-bitmask.rs
+index 98f63c165f3..e8bb335c5b0 100644
+--- a/tests/assembly-llvm/simd-bitmask.rs
++++ b/tests/assembly-llvm/simd-bitmask.rs
+@@ -11,7 +11,7 @@
+ //@ [aarch64] min-llvm-version: 23
+ //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
+ //@ [aarch64] needs-llvm-components: aarch64
+-//@ [aarch64-llvm-pre-23] ignore-llvm-version: 23 - 99
++//@ [aarch64-llvm-pre-23] max-llvm-major-version: 22
+ //@ [aarch64-llvm-pre-23] compile-flags: --target=aarch64-unknown-linux-gnu
+ //@ [aarch64-llvm-pre-23] needs-llvm-components: aarch64
+ //@ assembly-output: emit-asm
+diff --git a/tests/codegen-llvm/array-equality.rs b/tests/codegen-llvm/array-equality.rs
+index 706caebdcb6..c0f716b6067 100644
+--- a/tests/codegen-llvm/array-equality.rs
++++ b/tests/codegen-llvm/array-equality.rs
+@@ -1,5 +1,5 @@
+ //@ revisions: llvm-current llvm-next
+-//@[llvm-current] ignore-llvm-version: 23-99
++//@[llvm-current] max-llvm-major-version: 22
+ //@[llvm-next] min-llvm-version: 23
+ //@ compile-flags: -Copt-level=3 -Z merge-functions=disabled
+ //@ only-x86_64
+diff --git a/tests/ui/explicit-tail-calls/support/bystack.rs b/tests/ui/explicit-tail-calls/support/bystack.rs
+index ddd9c79f5c7..c89ad194f8b 100644
+--- a/tests/ui/explicit-tail-calls/support/bystack.rs
++++ b/tests/ui/explicit-tail-calls/support/bystack.rs
+@@ -36,11 +36,11 @@
+ //@ revisions: loongarch32
+ //@[loongarch32] compile-flags: --target loongarch32-unknown-none
+ //@[loongarch32] needs-llvm-components: loongarch
+-//@[loongarch32] ignore-llvm-version: 22 - 23
++//@[loongarch32] max-llvm-major-version: 21
+ //@ revisions: loongarch64
+ //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
+ //@[loongarch64] needs-llvm-components: loongarch
+-//@[loongarch64] ignore-llvm-version: 22 - 23
++//@[loongarch64] max-llvm-major-version: 21
+ //@ revisions: bpf
+ //@[bpf] compile-flags: --target bpfeb-unknown-none
+ //@[bpf] needs-llvm-components: bpf
+diff --git a/tests/ui/explicit-tail-calls/support/byval.rs b/tests/ui/explicit-tail-calls/support/byval.rs
+index f451a953f2a..e6f26b9292e 100644
+--- a/tests/ui/explicit-tail-calls/support/byval.rs
++++ b/tests/ui/explicit-tail-calls/support/byval.rs
+@@ -36,11 +36,11 @@
+ //@ revisions: loongarch32
+ //@[loongarch32] compile-flags: --target loongarch32-unknown-none
+ //@[loongarch32] needs-llvm-components: loongarch
+-//@[loongarch32] ignore-llvm-version: 22 - 23
++//@[loongarch32] max-llvm-major-version: 21
+ //@ revisions: loongarch64
+ //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
+ //@[loongarch64] needs-llvm-components: loongarch
+-//@[loongarch64] ignore-llvm-version: 22 - 23
++//@[loongarch64] max-llvm-major-version: 21
+ //@ revisions: bpf
+ //@[bpf] compile-flags: --target bpfeb-unknown-none
+ //@[bpf] needs-llvm-components: bpf
+diff --git a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
+index 5834255f3d3..c3090a20e4d 100644
+--- a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
++++ b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
+@@ -14,7 +14,6 @@ pub unsafe fn foo(x: &mut Copied<Iter<'_, u32>>) -> u32 {
+     // CHECK-NOT: br {{.*}}
+     // CHECK-NOT: select
+     // CHECK: [[RET:%.*]] = load i32, ptr
+-    // CHECK-NEXT: assume
+-    // CHECK-NEXT: ret i32 [[RET]]
++    // CHECK: ret i32 [[RET]]
+     x.next().unwrap_unchecked()
+ }
diff --git a/meta/recipes-devtools/rust/rust-source.inc b/meta/recipes-devtools/rust/rust-source.inc
index dd3e89a097..d87271b29c 100644
--- a/meta/recipes-devtools/rust/rust-source.inc
+++ b/meta/recipes-devtools/rust/rust-source.inc
@@ -7,6 +7,7 @@ SRC_URI += "https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n<https://static.rust-lang.org/dist/rustc-$%7BRUST_VERSION%7D-src.tar.xz;n>
             file://0001-src-core-build_steps-tool.rs-switch-off-lto-for-rust.patch;patchdir=${RUSTSRC} \
             file://0002-Fix-rust-build-failure-with-unstable-options.patch;patchdir=${RUSTSRC} \
             file://0003-bootstrap-skip-StdarchVerify-when-remote-testing.patch;patchdir=${RUSTSRC} \
+            file://0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch;patchdir=${RUSTSRC} \
 "
 SRC_URI[rust.sha256sum] = "271fa73d8174f53d713c46a8310da7bf7cfdcfb8b7cfd1c2b74b84a83ae9fb1e"

--
2.43.0





-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#244695): https://lists.openembedded.org/g/openembedded-core/message/244695
Mute This Topic: https://lists.openembedded.org/mt/120998122/8968818
Group Owner: openembedded-core+owner@lists.openembedded.org<mailto:openembedded-core+owner@lists.openembedded.org>
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com<mailto:SunilKumar.Dora@windriver.com>]
-=-=-=-=-=-=-=-=-=-=-=-




[-- Attachment #2: Type: text/html, Size: 45151 bytes --]

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release
  2026-09-01  3:37     ` [OE-core] " Dora, Sunil Kumar
@ 2026-09-01 12:49       ` Richard Purdie
  0 siblings, 0 replies; 30+ messages in thread
From: Richard Purdie @ 2026-09-01 12:49 UTC (permalink / raw)
  To: SunilKumar.Dora, raj.khem@gmail.com
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 2808 bytes --]

On Tue, 2026-09-01 at 03:37 +0000, Dora, Sunil Kumar via
lists.openembedded.org wrote:
> 
> On 8/31/2026 1:22 AM, Khem Raj via lists.openembedded.org wrote:
> > 
> > On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com>
> > wrote:
> > > -@@ -762,6 +762,7 @@ static Triple::EnvironmentType
> > > parseEnvironment(StringRef EnvironmentName) {
> > > -       .StartsWith("eabihf", Triple::EABIHF)
> > > -       .StartsWith("eabi", Triple::EABI)
> > > -       .StartsWith("gnuabin32", Triple::GNUABIN32)
> > > -+      .StartsWith("gnun32", Triple::GNUABIN32)
> > > -       .StartsWith("gnuabi64", Triple::GNUABI64)
> > > -       .StartsWith("gnueabihft64", Triple::GNUEABIHFT64)
> > > -       .StartsWith("gnueabihf", Triple::GNUEABIHF)
> > > -@@ -1087,6 +1088,7 @@ Triple::Triple(std::string &&Str) :
> > > Data(std::move(Str)) {
> > > +@@ -755,6 +755,7 @@ static Triple::OSType parseOS(StringRef
> > > OSName) {
> > > + 
> > > + static Triple::EnvironmentType parseEnvironment(StringRef
> > > EnvironmentName) {
> > > +   return StringSwitch<Triple::EnvironmentType>(EnvironmentName)
> > > ++      .StartsWith("gnuabin32", Triple::GNUABIN32)
> > > + #define TRIPLE_ENV(Enum, Name) .StartsWith(Name, Triple::Enum)
> > > + #include "llvm/TargetParser/TripleName.def"
> > > +       .Default(Triple::UnknownEnvironment);
> > > +@@ -1106,6 +1107,7 @@ Triple::Triple(std::string &&Str) :
> > > Data(std::move(Str)) {
> > >         Environment =
> > >             StringSwitch<Triple::EnvironmentType>(Components[0])
> > >                 .StartsWith("mipsn32", Triple::GNUABIN32)
> > > 
> > 
> >    .def already has an alias mechanism (TRIPLE_VENDOR_ALIAS appears
> > in the vendor rework) — ifTRIPLE_ENV_ALIAS exists too, using it for
> > gnuabin32 would keep the compat spelling in the table itself
> > instead of hand-editingparseEnvironment, which will rebase more
> > cleanly next   
> 
> TRIPLE_ENV_ALIAS doesn't exist yet, I checked 23.1.0 and current
> main. Only the OS and vendor sections have alias macros.
> 
> Since Triple.cpp is the only file that includes TripleName.def, the
> patch can add the macro itself the same way the other two sections
> do. I tried it here, the alias line sits in the table next to gnun32
> and one extra #define in parseEnvironment replaces the hand edit.
> The stack applies clean and llvm builds fine with it.
> 
> Is this what you had in mind? I can fold it into v2. We could also
> send TRIPLE_ENV_ALIAS to llvm as a small NFC patch, then this
> carries just two table lines going forward.

Can you both please trim quoted replies!

I tend to ignore it but trying to find this detail in hundreds of lines
was painful.

Cheers,

Richard

[-- Attachment #2: Type: text/html, Size: 4100 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23
  2026-09-01  5:17     ` [OE-core] " Dora, Sunil Kumar
@ 2026-09-03  1:08       ` Khem Raj
  0 siblings, 0 replies; 30+ messages in thread
From: Khem Raj @ 2026-09-03  1:08 UTC (permalink / raw)
  To: Dora, Sunil Kumar
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 37394 bytes --]

On Mon, Aug 31, 2026 at 10:17 PM Dora, Sunil Kumar <
SunilKumar.Dora@windriver.com> wrote:

> On 8/31/2026 1:17 AM, Khem Raj via lists.openembedded.org wrote:
>
> *CAUTION: This email comes from a non Wind River email account!*
> Do not click links or open attachments unless you recognize the sender and
> know the content is safe.
> I wonder if each backport should have been a patch of its own. It would
> make it easy to maintain of some of them get backported to later versions
> of rust.
>
> I checked with Deepesh. These all exist for the same llvm 23 bump, mostly
> test guarding plus the one AssignGUID wrapper fix, and they become
> redundant
> together once we move to a rust that supports LLVM 23. So one patch keeps
> it simple here. For real compiler or library backports we agree
> separate patches make life easier and we will do that going forward. Ok to
> keep this one as is?
>

OK, Lets try it this way, Since we will bump minor versions of llvm during
its lifetime we will see if it will cause conflicts too much.


>
> Thanks,
> Sunil Dora
>
>
> On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:
>
>> From: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>>
>> Backport upstream Rust commits to address build and oe-selftest
>> failures introduced by the LLVM 23 upgrade.
>>
>> New patch:
>> 0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>> The backported changes update LLVM 23 compatibility in the Rust LLVM
>> wrapper and adjust affected LLVM codegen tests.
>>
>> Selftest Changes:
>> Exclude the following Windows-specific test from oe-selftest,
>> as it is not relevant.
>> tests/assembly-llvm/x86_64-windows-float-abi.rs
>>
>> Excluded tests:
>> +---------+---------+---------+
>> | Before  |  After  | Skipped |
>> +---------+---------+---------+
>> |   43    |   44    |   +1    |
>> +---------+---------+---------+
>>
>> Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>> Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
>> ---
>>  meta/lib/oeqa/selftest/cases/rust.py          |   1 +
>>  ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
>>  meta/recipes-devtools/rust/rust-source.inc    |   1 +
>>  3 files changed, 663 insertions(+)
>>  create mode 100644
>> meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>>
>> diff --git a/meta/lib/oeqa/selftest/cases/rust.py
>> b/meta/lib/oeqa/selftest/cases/rust.py
>> index fa8a8c1e7c..645b5d5fbf 100644
>> --- a/meta/lib/oeqa/selftest/cases/rust.py
>> +++ b/meta/lib/oeqa/selftest/cases/rust.py
>> @@ -83,6 +83,7 @@ class RustSelfTestSystemEmulated(OESelftestTestCase,
>> OEPTestResultTestCase):
>>                              'src/tools/tidy',
>>
>>  'tests/assembly-llvm/asm/aarch64-outline-atomics.rs',
>>                              'tests/assembly-llvm/c-variadic/arm.rs',
>> +
>> 'tests/assembly-llvm/x86_64-windows-float-abi.rs',
>>                              'tests/codegen-llvm/thread-local.rs',
>>                              'tests/mir-opt/',
>>                              'tests/run-make',
>> diff --git
>> a/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>> b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>> new file mode 100644
>> index 0000000000..1e1bf089f1
>> --- /dev/null
>> +++
>> b/meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>> @@ -0,0 +1,661 @@
>> +Backport commits that fix build and oe-selftest failures seen with llvm
>> 23
>> +
>> +Upstream-Status: Backport [
>> https://github.com/rust-lang/rust/commit/b8d3a4ac9cfeb81d1e929fe6eab0af4b77ba3bb4
>> ]
>> +Upstream-Status: Backport [
>> https://github.com/rust-lang/rust/commit/d4a24cd6e18b98326429d8c7e7bbb269da14a5aa
>> ]
>> +Upstream-Status: Backport [
>> https://github.com/rust-lang/rust/commit/20ac2125a2142c9bde53ca06d9b3cfb6941fd437
>> ]
>> +Upstream-Status: Backport [
>> https://github.com/rust-lang/rust/commit/2d18054569d1169bfae7ce21e5c7111f32f16774
>> ]
>> +Upstream-Status: Backport [
>> https://github.com/rust-lang/rust/commit/e2159107f6ebc615ba6a92960d65528baf90cd35
>> ]
>> +Upstream-Status: Backport [
>> https://github.com/rust-lang/rust/commit/283a60b64339d611b76a4ed2f9286f417b269b2f
>> ]
>> +Upstream-Status: Backport [
>> https://github.com/rust-lang/rust/commit/61d9ba28a99f073fbeb19dbb552ddf343aef62f0
>> ]
>> +
>> +Signed-off-by: Deepesh Varatharajan <Deepesh.Varatharajan@windriver.com>
>> +
>> +diff --git a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
>> b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
>> +index fe5b8edce4a..e4807f10805 100644
>> +--- a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
>> ++++ b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
>> +@@ -49,6 +49,9 @@
>> + #include "llvm/Transforms/Instrumentation/RealtimeSanitizer.h"
>> + #include "llvm/Transforms/Instrumentation/ThreadSanitizer.h"
>> + #include "llvm/Transforms/Scalar/AnnotationRemarks.h"
>> ++#if LLVM_VERSION_GE(23, 0)
>> ++#include "llvm/Transforms/Utils/AssignGUID.h"
>> ++#endif
>> + #include "llvm/Transforms/Utils/CanonicalizeAliases.h"
>> + #include "llvm/Transforms/Utils/FunctionImportUtils.h"
>> + #include "llvm/Transforms/Utils/NameAnonGlobals.h"
>> +@@ -925,6 +928,9 @@
>> +   if (NeedThinLTOBufferPasses) {
>> +     MPM.addPass(CanonicalizeAliasesPass());
>> +     MPM.addPass(NameAnonGlobalPass());
>> ++#if LLVM_VERSION_GE(23, 0)
>> ++    MPM.addPass(AssignGUIDPass());
>> ++#endif
>> +   }
>> +   // For `-Copt-level=0`, and the pre-link fat/thin LTO stages.
>> +   if (ThinLTOBufferRef && *ThinLTOBufferRef == nullptr) {
>> +@@ -1464,6 +1470,9 @@
>> +         PB.registerLoopAnalyses(LAM);
>> +         PB.crossRegisterProxies(LAM, FAM, CGAM, MAM);
>> +         ModulePassManager MPM;
>> ++#if LLVM_VERSION_GE(23, 0)
>> ++        MPM.addPass(AssignGUIDPass());
>> ++#endif
>> +         MPM.addPass(ThinLTOBitcodeWriterPass(OS, nullptr));
>> +         MPM.run(*unwrap(M), MAM);
>> +       } else {
>> +diff --git a/tests/codegen-llvm/bpf-allows-unaligned.rs
>> b/tests/codegen-llvm/bpf-allows-unaligned.rs
>> +index c7a70d5b2e5..7e95a56d984 100644
>> +--- a/tests/codegen-llvm/bpf-allows-unaligned.rs
>> ++++ b/tests/codegen-llvm/bpf-allows-unaligned.rs
>> +@@ -5,7 +5,7 @@
>> +
>> + #[no_mangle]
>> + #[target_feature(enable = "allows-misaligned-mem-access")]
>> +-// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg)
>> unnamed_addr #0 {
>> ++// CHECK: define noundef zeroext i8 @foo(i8 noundef returned %arg)
>> unnamed_addr #0
>> + pub unsafe fn foo(arg: u8) -> u8 {
>> +     arg
>> + }
>> +diff --git a/tests/codegen-llvm/branch-protection.rs
>> b/tests/codegen-llvm/branch-protection.rs
>> +index ed1cb2cd137..11847c256d6 100644
>> +--- a/tests/codegen-llvm/branch-protection.rs
>> ++++ b/tests/codegen-llvm/branch-protection.rs
>> +@@ -22,7 +22,7 @@
>> + use minicore::*;
>> +
>> + // A basic test function.
>> +-// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]] {
>> ++// CHECK: @test(){{.*}} [[ATTR:#[0-9]+]]
>> + #[no_mangle]
>> + pub fn test() {}
>> +
>> +diff --git a/tests/codegen-llvm/frame-pointer-cli-control.rs
>> b/tests/codegen-llvm/frame-pointer-cli-control.rs
>> +index 911a5f03cbc..79cdfc70f1a 100644
>> +--- a/tests/codegen-llvm/frame-pointer-cli-control.rs
>> ++++ b/tests/codegen-llvm/frame-pointer-cli-control.rs
>> +@@ -45,7 +45,7 @@
>> +
>> + extern crate minicore;
>> +
>> +-// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
>> ++// CHECK: i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
>> + #[no_mangle]
>> + pub fn peach(x: u32) -> u32 {
>> +     x
>> +diff --git a/tests/codegen-llvm/frame-pointer.rs
>> b/tests/codegen-llvm/frame-pointer.rs
>> +index 1d0dd762826..a52d95a2386 100644
>> +--- a/tests/codegen-llvm/frame-pointer.rs
>> ++++ b/tests/codegen-llvm/frame-pointer.rs
>> +@@ -18,7 +18,7 @@
>> + extern crate minicore;
>> + use minicore::*;
>> +
>> +-// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]] {
>> ++// CHECK: define i32 @peach{{.*}}[[PEACH_ATTRS:\#[0-9]+]]
>> + #[no_mangle]
>> + pub fn peach(x: u32) -> u32 {
>> +     x
>> +diff --git a/tests/codegen-llvm/gpu-convergent.rs
>> b/tests/codegen-llvm/gpu-convergent.rs
>> +index bb9271ab699..376d65a3d4a 100644
>> +--- a/tests/codegen-llvm/gpu-convergent.rs
>> ++++ b/tests/codegen-llvm/gpu-convergent.rs
>> +@@ -17,7 +17,7 @@
>> +     fn ext();
>> + }
>> +
>> +-// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr
>> #[[ATTR:[0-9]+]] {
>> ++// CHECK: define {{.*}}_kernel void @fun(i32{{.*}}) unnamed_addr
>> #[[ATTR:[0-9]+]]
>> + // CHECK: declare void @ext() unnamed_addr #[[ATTR]]
>> + // CHECK: attributes #[[ATTR]] = {{.*}} convergent
>> + #[no_mangle]
>> +diff --git a/tests/codegen-llvm/instrument-coverage/testprog.rs
>> b/tests/codegen-llvm/instrument-coverage/testprog.rs
>> +index ef61ede6de8..67c49c438f9 100644
>> +--- a/tests/codegen-llvm/instrument-coverage/testprog.rs
>> ++++ b/tests/codegen-llvm/instrument-coverage/testprog.rs
>> +@@ -101,7 +101,7 @@ fn main() {
>> + // CHECK-SAME:   @__llvm_prf_nm
>> + // CHECK-SAME:   section "llvm.metadata"
>> +
>> +-// CHECK:        define internal { {{.*}} }
>> @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}} {
>> ++// CHECK:        define internal { {{.*}} }
>> @_R{{[a-zA-Z0-9_]+}}testprog14will_be_called() unnamed_addr #{{[0-9]+}}
>> + // CHECK-NEXT:   start:
>> + // CHECK-NOT:    define internal
>> + // CHECK:        atomicrmw add ptr
>> +@@ -109,7 +109,7 @@ fn main() {
>> +
>> + // CHECK:        declare void @llvm.instrprof.increment(ptr, i64, i32,
>> i32) #[[LLVM_INSTRPROF_INCREMENT_ATTR:[0-9]+]]
>> +
>> +-// WIN:          define linkonce_odr hidden i32
>> @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]]
>> comdat {{.*}}{
>> ++// WIN:          define linkonce_odr hidden i32
>> @__llvm_profile_runtime_user() #[[LLVM_PROFILE_RUNTIME_USER_ATTR:[0-9]+]]
>> comdat {{.*}}
>> + // WIN-NEXT:     %1 = load i32, ptr @__llvm_profile_runtime
>> + // WIN-NEXT:     ret i32 %1
>> + // WIN-NEXT:     }
>> +diff --git a/tests/codegen-llvm/link_section.rs
>> b/tests/codegen-llvm/link_section.rs
>> +index f196ea86c44..61bde683c0a 100644
>> +--- a/tests/codegen-llvm/link_section.rs
>> ++++ b/tests/codegen-llvm/link_section.rs
>> +@@ -29,7 +29,7 @@ pub enum E {
>> + #[link_section = "__TEST,three"]
>> + pub static VAR3: E = E::B(1.);
>> +
>> +-// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section
>> "__TEST,four" {
>> ++// CHECK: define {{(dso_local )?}}void @fn1() {{.*}} section
>> "__TEST,four"
>> + #[no_mangle]
>> + #[link_section = "__TEST,four"]
>> + pub fn fn1() {}
>> +diff --git
>> a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
>> b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
>> +index 7639ce7b104..5b1aa97ab33 100644
>> +---
>> a/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
>> ++++
>> b/tests/codegen-llvm/sanitizer/cfi/emit-type-metadata-itanium-cxx-abi-normalized-generalized.rs
>> +@@ -7,21 +7,21 @@
>> +
>> + pub fn foo(f: fn(i32) -> i32, arg: i32) -> i32 {
>> +     // CHECK-LABEL: define{{.*}}foo
>> +-    // CHECK-SAME:  {{.*}}![[TYPE1:[0-9]+]]
>> ++    // CHECK-SAME:  {{.*}}!type ![[TYPE1:[0-9]+]]
>> +     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata
>> !"_ZTSFu3i32S_E.normalized.generalized")
>> +     f(arg)
>> + }
>> +
>> + pub fn bar(f: fn(i32, i32) -> i32, arg1: i32, arg2: i32) -> i32 {
>> +     // CHECK-LABEL: define{{.*}}bar
>> +-    // CHECK-SAME:  {{.*}}![[TYPE2:[0-9]+]]
>> ++    // CHECK-SAME:  {{.*}}!type ![[TYPE2:[0-9]+]]
>> +     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata
>> !"_ZTSFu3i32S_S_E.normalized.generalized")
>> +     f(arg1, arg2)
>> + }
>> +
>> + pub fn baz(f: fn(i32, i32, i32) -> i32, arg1: i32, arg2: i32, arg3:
>> i32) -> i32 {
>> +     // CHECK-LABEL: define{{.*}}baz
>> +-    // CHECK-SAME:  {{.*}}![[TYPE3:[0-9]+]]
>> ++    // CHECK-SAME:  {{.*}}!type ![[TYPE3:[0-9]+]]
>> +     // CHECK:       call i1 @llvm.type.test(ptr {{%f|%0}}, metadata
>> !"_ZTSFu3i32S_S_S_E.normalized.generalized")
>> +     f(arg1, arg2, arg3)
>> + }
>> +diff --git
>> a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
>> b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
>> +index 35317b0dd39..3df2d569f9a 100644
>> +--- a/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
>> ++++ b/tests/codegen-llvm/some-non-zero-from-atomic-optimization.rs
>> +@@ -72,7 +72,7 @@ pub unsafe fn some_non_zero_from_atomic_get() ->
>> Option<NonZeroUsize> {
>> + ///
>> + /// The way we check that the LLVM IR is correct is by making sure that
>> neither
>> + /// `panic` nor `unreachable` is part of the LLVM IR:
>> +-// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2()
>> {{.*}} {
>> ++// CHECK-LABEL: define {{.*}} i64 @some_non_zero_from_atomic_get2()
>> {{.*}}
>> + // CHECK-NOT: panic
>> + // CHECK-NOT: unreachable
>> + #[no_mangle]
>> +diff --git a/tests/codegen-llvm/target-feature-negative-implication.rs
>> b/tests/codegen-llvm/target-feature-negative-implication.rs
>> +index a9cdca42839..376599738e5 100644
>> +--- a/tests/codegen-llvm/target-feature-negative-implication.rs
>> ++++ b/tests/codegen-llvm/target-feature-negative-implication.rs
>> +@@ -13,7 +13,7 @@
>> + #[no_mangle]
>> + pub unsafe fn banana() {
>> +     // CHECK-LABEL: @banana()
>> +-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
>> ++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
>> + }
>> +
>> + // CHECK: attributes [[BANANAATTRS]]
>> +diff --git a/tests/codegen-llvm/target-feature-overrides.rs
>> b/tests/codegen-llvm/target-feature-overrides.rs
>> +index 2adc8ee6f53..3bf05c7977e 100644
>> +--- a/tests/codegen-llvm/target-feature-overrides.rs
>> ++++ b/tests/codegen-llvm/target-feature-overrides.rs
>> +@@ -23,7 +23,7 @@
>> + #[no_mangle]
>> + pub unsafe fn apple() -> u32 {
>> +     // CHECK-LABEL: @apple()
>> +-    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]] {
>> ++    // CHECK-SAME: [[APPLEATTRS:#[0-9]+]]
>> +     // CHECK: {{.*}}call{{.*}}@peach
>> +     peach()
>> + }
>> +@@ -32,7 +32,7 @@ pub unsafe fn apple() -> u32 {
>> + #[no_mangle]
>> + pub unsafe fn banana() -> u32 {
>> +     // CHECK-LABEL: @banana()
>> +-    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]] {
>> ++    // CHECK-SAME: [[BANANAATTRS:#[0-9]+]]
>> +     // COMPAT: {{.*}}call{{.*}}@peach
>> +     // INCOMPAT: {{.*}}call{{.*}}@apple
>> +     apple() // Compatible for inline in COMPAT revision and can't be
>> inlined in INCOMPAT
>> +diff --git a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
>> +index ecace722e0d..279780e3a7a 100644
>> +--- a/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/aapcs-unwind-abi.rs
>> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
>> + // `aapcs-unwind` extern functions. `aapcs-unwind` functions MUST NOT
>> have this attribute. We
>> + // disable optimizations above to prevent LLVM from inferring the
>> attribute.
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "aapcs" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "aapcs-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
>> +index 46c08b5fc4f..1b3312839e3 100644
>> +--- a/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/c-unwind-abi.rs
>> +@@ -7,11 +7,11 @@
>> +
>> + #![crate_type = "lib"]
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "C" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "C-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
>> +index 8e643d6ce49..6f4eafb353c 100644
>> +--- a/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/cdecl-unwind-abi.rs
>> +@@ -7,11 +7,11 @@
>> +
>> + #![crate_type = "lib"]
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "cdecl" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "cdecl-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
>> +index 7df46813ed1..51c6fd15b9c 100644
>> +--- a/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/fastcall-unwind-abi.rs
>> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
>> + // `fastcall-unwind` extern functions. `fastcall-unwind` functions MUST
>> NOT have this attribute. We
>> + // disable optimizations above to prevent LLVM from inferring the
>> attribute.
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "fastcall" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "fastcall-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
>> +index cc06ee12549..b5fcea52b4d 100644
>> +--- a/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/stdcall-unwind-abi.rs
>> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
>> + // extern functions. `stdcall-unwind` functions MUST NOT have this
>> attribute. We disable
>> + // optimizations above to prevent LLVM from inferring the attribute.
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "stdcall" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "stdcall-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
>> +index 5f910248346..15fce95fe28 100644
>> +--- a/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/system-unwind-abi.rs
>> +@@ -7,11 +7,11 @@
>> +
>> + #![crate_type = "lib"]
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "system" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "system-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
>> +index 69bfaf80b4b..1293e7c0a5f 100644
>> +--- a/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/sysv64-unwind-abi.rs
>> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
>> + // `sysv64-unwind` extern functions. `sysv64-unwind` functions MUST NOT
>> have this attribute. We
>> + // disable optimizations above to prevent LLVM from inferring the
>> attribute.
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "sysv64" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "sysv64-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
>> +index 05f6b8b70e1..a9b6c34ee58 100644
>> +--- a/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/thiscall-unwind-abi.rs
>> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
>> + // `thiscall-unwind` extern functions. `thiscall-unwind` functions MUST
>> NOT have this attribute. We
>> + // disable optimizations above to prevent LLVM from inferring the
>> attribute.
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "thiscall" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "thiscall-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
>> +index d001a16b32a..8cedb55ae1d 100644
>> +--- a/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/vectorcall-unwind-abi.rs
>> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
>> + // `vectorcall-unwind` extern functions. `vectorcall-unwind` functions
>> MUST NOT have this attribute.
>> + // We disable optimizations above to prevent LLVM from inferring the
>> attribute.
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "vectorcall" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "vectorcall-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
>> b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
>> +index 257f00b54e4..2a3ad330406 100644
>> +--- a/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
>> ++++ b/tests/codegen-llvm/unwind-abis/win64-unwind-abi.rs
>> +@@ -16,11 +16,11 @@ pub trait Sized: MetaSized {}
>> + // `win64-unwind` extern functions. `win64-unwind` functions MUST NOT
>> have this attribute. We
>> + // disable optimizations above to prevent LLVM from inferring the
>> attribute.
>> +
>> +-// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0 {
>> ++// CHECK: @rust_item_that_cannot_unwind() unnamed_addr #0
>> + #[no_mangle]
>> + pub extern "win64" fn rust_item_that_cannot_unwind() {}
>> +
>> +-// CHECK: @rust_item_that_can_unwind() unnamed_addr #1 {
>> ++// CHECK: @rust_item_that_can_unwind() unnamed_addr #1
>> + #[no_mangle]
>> + pub extern "win64-unwind" fn rust_item_that_can_unwind() {}
>> +
>> +diff --git a/tests/assembly-llvm/slice-is_ascii.rs
>> b/tests/assembly-llvm/slice-is_ascii.rs
>> +index e53cd5160cf..6d660e78147 100644
>> +--- a/tests/assembly-llvm/slice-is_ascii.rs
>> ++++ b/tests/assembly-llvm/slice-is_ascii.rs
>> +@@ -6,6 +6,11 @@
>> + //@ only-x86_64
>> + //@ ignore-sgx
>> +
>> ++// No longer optimizes as desired, tracked at:
>> ++// https://github.com/rust-lang/rust/issues/154141
>> ++// https://github.com/llvm/llvm-project/issues/209216
>> ++//@ max-llvm-major-version: 22
>> ++
>> + #![feature(str_internals)]
>> +
>> + // CHECK-LABEL: is_ascii_simple_demo:
>> +diff --git a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
>> b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
>> +index 40d16886c6d..d3698fda5fe 100644
>> +--- a/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
>> ++++ b/tests/assembly-llvm/simd-intrinsic-mask-reduce.rs
>> +@@ -1,12 +1,16 @@
>> + // verify that simd mask reductions do not introduce additional bit
>> shift operations
>> + //@ add-minicore
>> +-//@ revisions: x86 aarch64
>> ++//@ revisions: x86 aarch64-llvm22 aarch64
>> + //@ [x86] compile-flags: --target=x86_64-unknown-linux-gnu -C
>> llvm-args=-x86-asm-syntax=intel
>> + // Set the base cpu explicitly, in case the default has been changed.
>> + //@ [x86] compile-flags: -C target-cpu=x86-64
>> + //@ [x86] needs-llvm-components: x86
>> ++//@ [aarch64-llvm22] compile-flags: --target=aarch64-unknown-linux-gnu
>> ++//@ [aarch64-llvm22] needs-llvm-components: aarch64
>> ++//@ [aarch64-llvm22] max-llvm-major-version: 22
>> + //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
>> + //@ [aarch64] needs-llvm-components: aarch64
>> ++//@ [aarch64] min-llvm-version: 23
>> + //@ assembly-output: emit-asm
>> + //@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
>> +
>> +@@ -33,12 +37,19 @@
>> +     // x86-NEXT: {{cmp ax, -1|cmp eax, 65535|xor eax, 65535}}
>> +     // x86-NEXT: sete al
>> +     //
>> ++    // aarch64-llvm22-NOT: shl
>> ++    // aarch64-llvm22: cmge v0.16b, v0.16b, #0
>> ++    // aarch64-llvm22-DAG: mov [[REG1:[a-z0-9]+]], #1
>> ++    // aarch64-llvm22-DAG: umaxv b0, v0.16b
>> ++    // aarch64-llvm22-NEXT: fmov [[REG2:[a-z0-9]+]], s0
>> ++    // aarch64-llvm22-NEXT: bic w0, [[REG1]], [[REG2]]
>> ++    //
>> +     // aarch64-NOT: shl
>> +     // aarch64: cmge v0.16b, v0.16b, #0
>> +-    // aarch64-DAG: mov [[REG1:[a-z0-9]+]], #1
>> +-    // aarch64-DAG: umaxv b0, v0.16b
>> +-    // aarch64-NEXT: fmov [[REG2:[a-z0-9]+]], s0
>> +-    // aarch64-NEXT: bic w0, [[REG1]], [[REG2]]
>> ++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
>> ++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
>> ++    // aarch64-NEXT: cmp [[REG2]], #0
>> ++    // aarch64-NEXT: cset w0, eq
>> +     simd_reduce_all(m)
>> + }
>> +
>> +@@ -50,10 +61,17 @@
>> +     // x86-NEXT: test eax, eax
>> +     // x86-NEXT: setne al
>> +     //
>> ++    // aarch64-llvm22-NOT: shl
>> ++    // aarch64-llvm22: cmlt v0.16b, v0.16b, #0
>> ++    // aarch64-llvm22-NEXT: umaxv b0, v0.16b
>> ++    // aarch64-llvm22-NEXT: fmov [[REG:[a-z0-9]+]], s0
>> ++    // aarch64-llvm22-NEXT: and w0, [[REG]], #0x1
>> ++    //
>> +     // aarch64-NOT: shl
>> +     // aarch64: cmlt v0.16b, v0.16b, #0
>> +-    // aarch64-NEXT: umaxv b0, v0.16b
>> +-    // aarch64-NEXT: fmov [[REG:[a-z0-9]+]], s0
>> +-    // aarch64-NEXT: and w0, [[REG]], #0x1
>> ++    // aarch64-NEXT: addp [[REG1:d[0-9]+]], v0.2d
>> ++    // aarch64-NEXT: fmov [[REG2:x[0-9]+]], [[REG1]]
>> ++    // aarch64-NEXT: cmp [[REG2]], #0
>> ++    // aarch64-NEXT: cset w0, ne
>> +     simd_reduce_any(m)
>> + }
>> +diff --git a/tests/codegen-llvm/asm/global_asm.rs
>> b/tests/codegen-llvm/asm/global_asm.rs
>> +index 32075daa3cf..8c1c4a3b588 100644
>> +--- a/tests/codegen-llvm/asm/global_asm.rs
>> ++++ b/tests/codegen-llvm/asm/global_asm.rs
>> +@@ -7,10 +7,10 @@
>> +
>> + use std::arch::global_asm;
>> +
>> +-// CHECK-LABEL: foo
>> + // CHECK: module asm
>> ++// CHECK-LABEL: foo
>> + // this regex will capture the correct unconditional branch inst.
>> +-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
>> ++// CHECK: "{{[[:space:]]+}}jmp baz"
>> + global_asm!(
>> +     r#"
>> +     .global foo
>> +diff --git a/tests/codegen-llvm/asm/global_asm_include.rs
>> b/tests/codegen-llvm/asm/global_asm_include.rs
>> +index 98be9c3e333..cad9901336b 100644
>> +--- a/tests/codegen-llvm/asm/global_asm_include.rs
>> ++++ b/tests/codegen-llvm/asm/global_asm_include.rs
>> +@@ -7,9 +7,9 @@
>> +
>> + use std::arch::global_asm;
>> +
>> +-// CHECK-LABEL: foo
>> + // CHECK: module asm
>> +-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
>> ++// CHECK-LABEL: foo
>> ++// CHECK: "{{[[:space:]]+}}jmp baz"
>> + global_asm!(include_str!("foo.s"));
>> +
>> + extern "C" {
>> +diff --git a/tests/codegen-llvm/asm/global_asm_x2.rs
>> b/tests/codegen-llvm/asm/global_asm_x2.rs
>> +index 9e3a00f0680..8c6f38289de 100644
>> +--- a/tests/codegen-llvm/asm/global_asm_x2.rs
>> ++++ b/tests/codegen-llvm/asm/global_asm_x2.rs
>> +@@ -8,12 +8,12 @@
>> +
>> + use core::arch::global_asm;
>> +
>> +-// CHECK-LABEL: foo
>> + // CHECK: module asm
>> +-// CHECK: module asm "{{[[:space:]]+}}jmp baz"
>> ++// CHECK-LABEL: foo
>> ++// CHECK: "{{[[:space:]]+}}jmp baz"
>> + // any other global_asm will be appended to this first block, so:
>> + // CHECK-LABEL: bar
>> +-// CHECK: module asm "{{[[:space:]]+}}jmp quux"
>> ++// CHECK: "{{[[:space:]]+}}jmp quux"
>> + global_asm!(
>> +     r#"
>> +     .global foo
>> +diff --git a/tests/codegen-llvm/array-cmp.rs
>> b/tests/codegen-llvm/array-cmp.rs
>> +index 0106b9c15c1..5b0a802f409 100644
>> +--- a/tests/codegen-llvm/array-cmp.rs
>> ++++ b/tests/codegen-llvm/array-cmp.rs
>> +@@ -2,6 +2,9 @@
>> +
>> + //@ compile-flags: -C opt-level=2
>> + //@ needs-deterministic-layouts (checks depend on tuple layout)
>> ++//@ revisions: LLVM22 LLVM23
>> ++//@ [LLVM22] max-llvm-major-version: 22
>> ++//@ [LLVM23] min-llvm-version: 23
>> +
>> + #![crate_type = "lib"]
>> +
>> +@@ -66,7 +69,8 @@ pub fn compare() -> bool {
>> +     // CHECK-NEXT: br i1 %[[EQ01]], label %{{.+}}, label %[[EXIT_U]]
>> +
>> +     // CHECK: [[DONE]]:
>> +-    // CHECK: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [ %{{.+}},
>> %[[EXIT_U]] ], [ true, %[[L11]] ]
>> ++    // LLVM22: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_S]] ], [
>> %{{.+}}, %[[EXIT_U]] ], [ true, %[[L11]] ]
>> ++    // LLVM23: %[[RET:.+]] = phi i1 [ %{{.+}}, %[[EXIT_U]] ], [
>> %{{.+}}, %[[EXIT_S]] ], [ true, %[[L11]] ]
>> +     // CHECK: ret i1 %[[RET]]
>> +
>> +     a <= b
>> +diff --git a/tests/codegen-llvm/enum/enum-match.rs
>> b/tests/codegen-llvm/enum/enum-match.rs
>> +index 6d8b97328f8..a0cba452e12 100644
>> +--- a/tests/codegen-llvm/enum/enum-match.rs
>> ++++ b/tests/codegen-llvm/enum/enum-match.rs
>> +@@ -1,5 +1,8 @@
>> + //@ compile-flags: -Copt-level=1
>> + //@ only-64bit
>> ++//@ revisions: LLVM22 LLVM23
>> ++//@ [LLVM22] max-llvm-major-version: 22
>> ++//@ [LLVM23] min-llvm-version: 23
>> +
>> + #![crate_type = "lib"]
>> + #![feature(core_intrinsics)]
>> +@@ -18,8 +21,9 @@ pub enum Enum0 {
>> + // CHECK-LABEL: define{{( dso_local)?}} noundef{{( range\(i8 [0-9]+,
>> [0-9]+\))?}} i8 @match0(i8{{.+}}%0)
>> + // CHECK-NEXT: start:
>> + // CHECK-NEXT: %[[IS_B:.+]] = icmp eq i8 %0, 2
>> +-// CHECK-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
>> +-// CHECK-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
>> ++// LLVM22-NEXT: %[[TRUNC:.+]] = and i8 %0, 1
>> ++// LLVM22-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %[[TRUNC]]
>> ++// LLVM23-NEXT: %[[R:.+]] = select i1 %[[IS_B]], i8 13, i8 %0
>> + // CHECK-NEXT: ret i8 %[[R]]
>> + #[no_mangle]
>> + pub fn match0(e: Enum0) -> u8 {
>> +diff --git a/tests/assembly-llvm/simd-bitmask.rs
>> b/tests/assembly-llvm/simd-bitmask.rs
>> +index 98f63c165f3..e8bb335c5b0 100644
>> +--- a/tests/assembly-llvm/simd-bitmask.rs
>> ++++ b/tests/assembly-llvm/simd-bitmask.rs
>> +@@ -11,7 +11,7 @@
>> + //@ [aarch64] min-llvm-version: 23
>> + //@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
>> + //@ [aarch64] needs-llvm-components: aarch64
>> +-//@ [aarch64-llvm-pre-23] ignore-llvm-version: 23 - 99
>> ++//@ [aarch64-llvm-pre-23] max-llvm-major-version: 22
>> + //@ [aarch64-llvm-pre-23] compile-flags:
>> --target=aarch64-unknown-linux-gnu
>> + //@ [aarch64-llvm-pre-23] needs-llvm-components: aarch64
>> + //@ assembly-output: emit-asm
>> +diff --git a/tests/codegen-llvm/array-equality.rs
>> b/tests/codegen-llvm/array-equality.rs
>> +index 706caebdcb6..c0f716b6067 100644
>> +--- a/tests/codegen-llvm/array-equality.rs
>> ++++ b/tests/codegen-llvm/array-equality.rs
>> +@@ -1,5 +1,5 @@
>> + //@ revisions: llvm-current llvm-next
>> +-//@[llvm-current] ignore-llvm-version: 23-99
>> ++//@[llvm-current] max-llvm-major-version: 22
>> + //@[llvm-next] min-llvm-version: 23
>> + //@ compile-flags: -Copt-level=3 -Z merge-functions=disabled
>> + //@ only-x86_64
>> +diff --git a/tests/ui/explicit-tail-calls/support/bystack.rs
>> b/tests/ui/explicit-tail-calls/support/bystack.rs
>> +index ddd9c79f5c7..c89ad194f8b 100644
>> +--- a/tests/ui/explicit-tail-calls/support/bystack.rs
>> ++++ b/tests/ui/explicit-tail-calls/support/bystack.rs
>> +@@ -36,11 +36,11 @@
>> + //@ revisions: loongarch32
>> + //@[loongarch32] compile-flags: --target loongarch32-unknown-none
>> + //@[loongarch32] needs-llvm-components: loongarch
>> +-//@[loongarch32] ignore-llvm-version: 22 - 23
>> ++//@[loongarch32] max-llvm-major-version: 21
>> + //@ revisions: loongarch64
>> + //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
>> + //@[loongarch64] needs-llvm-components: loongarch
>> +-//@[loongarch64] ignore-llvm-version: 22 - 23
>> ++//@[loongarch64] max-llvm-major-version: 21
>> + //@ revisions: bpf
>> + //@[bpf] compile-flags: --target bpfeb-unknown-none
>> + //@[bpf] needs-llvm-components: bpf
>> +diff --git a/tests/ui/explicit-tail-calls/support/byval.rs
>> b/tests/ui/explicit-tail-calls/support/byval.rs
>> +index f451a953f2a..e6f26b9292e 100644
>> +--- a/tests/ui/explicit-tail-calls/support/byval.rs
>> ++++ b/tests/ui/explicit-tail-calls/support/byval.rs
>> +@@ -36,11 +36,11 @@
>> + //@ revisions: loongarch32
>> + //@[loongarch32] compile-flags: --target loongarch32-unknown-none
>> + //@[loongarch32] needs-llvm-components: loongarch
>> +-//@[loongarch32] ignore-llvm-version: 22 - 23
>> ++//@[loongarch32] max-llvm-major-version: 21
>> + //@ revisions: loongarch64
>> + //@[loongarch64] compile-flags: --target loongarch64-unknown-linux-gnu
>> + //@[loongarch64] needs-llvm-components: loongarch
>> +-//@[loongarch64] ignore-llvm-version: 22 - 23
>> ++//@[loongarch64] max-llvm-major-version: 21
>> + //@ revisions: bpf
>> + //@[bpf] compile-flags: --target bpfeb-unknown-none
>> + //@[bpf] needs-llvm-components: bpf
>> +diff --git a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
>> b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
>> +index 5834255f3d3..c3090a20e4d 100644
>> +--- a/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
>> ++++ b/tests/codegen-llvm/issues/issue-107681-unwrap_unchecked.rs
>> +@@ -14,7 +14,6 @@ pub unsafe fn foo(x: &mut Copied<Iter<'_, u32>>) ->
>> u32 {
>> +     // CHECK-NOT: br {{.*}}
>> +     // CHECK-NOT: select
>> +     // CHECK: [[RET:%.*]] = load i32, ptr
>> +-    // CHECK-NEXT: assume
>> +-    // CHECK-NEXT: ret i32 [[RET]]
>> ++    // CHECK: ret i32 [[RET]]
>> +     x.next().unwrap_unchecked()
>> + }
>> diff --git a/meta/recipes-devtools/rust/rust-source.inc
>> b/meta/recipes-devtools/rust/rust-source.inc
>> index dd3e89a097..d87271b29c 100644
>> --- a/meta/recipes-devtools/rust/rust-source.inc
>> +++ b/meta/recipes-devtools/rust/rust-source.inc
>> @@ -7,6 +7,7 @@ SRC_URI += "
>> https://static.rust-lang.org/dist/rustc-${RUST_VERSION}-src.tar.xz;n
>>
>> file://0001-src-core-build_steps-tool.rs-switch-off-lto-for-rust.patch;patchdir=${RUSTSRC}
>> \
>>
>> file://0002-Fix-rust-build-failure-with-unstable-options.patch;patchdir=${RUSTSRC}
>> \
>>
>> file://0003-bootstrap-skip-StdarchVerify-when-remote-testing.patch;patchdir=${RUSTSRC}
>> \
>> +
>> file://0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch;patchdir=${RUSTSRC}
>> \
>>  "
>>  SRC_URI[rust.sha256sum] =
>> "271fa73d8174f53d713c46a8310da7bf7cfdcfb8b7cfd1c2b74b84a83ae9fb1e"
>>
>> --
>> 2.43.0
>>
>>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#244695): https://lists.openembedded.org/g/openembedded-core/message/244695
> Mute This Topic: https://lists.openembedded.org/mt/120998122/8968818
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>
>
>

[-- Attachment #2: Type: text/html, Size: 42277 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
  2026-09-01  4:59   ` [OE-core] " Dora, Sunil Kumar
@ 2026-09-03  1:10     ` Khem Raj
  2026-09-03 23:46       ` Khem Raj
  0 siblings, 1 reply; 30+ messages in thread
From: Khem Raj @ 2026-09-03  1:10 UTC (permalink / raw)
  To: Dora, Sunil Kumar
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 15876 bytes --]

On Mon, Aug 31, 2026 at 9:59 PM Dora, Sunil Kumar <
SunilKumar.Dora@windriver.com> wrote:

> On 8/31/2026 1:23 AM, Khem Raj via lists.openembedded.org wrote:
>
> *CAUTION: This email comes from a non Wind River email account!*
> Do not click links or open attachments unless you recognize the sender and
> know the content is safe.
> Looks pretty good to me. I have few feedback comments, not a merge blocker
> but good to consider for future ease of porting.
>
> Thanks Khem.
>
> Quick update on the upstream side since the series went out.
>
> The clang half of the ssp_nonshared patch (0004 in the stack) was *merged
> *into llvm main yesterday, commit fd974c429301
> <https://github.com/llvm/llvm-project/commit/fd974c4293015388337e2f66f817a23e5873389f>,
> reviewed by
> MaskRay (Original PR #219828
> <https://github.com/llvm/llvm-project/pull/219828> ). A backport to
> release/23.x is open as PR #220136
> <https://github.com/llvm/llvm-project/pull/220136>.
> If that lands I will flip 0004 to Upstream-Status: Backport, and at the
> next upgrade the patch goes away entirely.
>

Thanks for following up on these patches, its really long time that we
clear this debt.


>
> The gcc half is on gcc-patches
> <https://gcc.gnu.org/pipermail/gcc-patches/2026-August/729351.html> as v2
> with bugzilla PR 127138
> <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=127138>. Sam James
> mentioned Gentoo has carried the same fix downstream for years.
>

yes, I know, again same, it will be nicer to get this list down as well.
Somethings are due to how OE has customized stuff so it will
be hard to get rid of but anything that gets upstreamed is a bonus.


>
> Thanks,
> Sunil Dora
>
>
> On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:
>
>> From: Sunil Dora <sunilkumar.dora@windriver.com>
>>
>> This upgrades clang/llvm from 22.1.8 to 23.1.0 and fixes the fallout
>> found while testing the result.
>>
>> The carried LLVM patch stack goes from 41 to 35: seven dropped
>> because 23.1.0 already contains the fix or the code they patched no
>> longer exists, three reworked for LLVM 23, and one added for a 32-bit
>> x86 build break, already merged in llvm-project.
>>
>> Please apply with git am --keep-cr: patch 8 fixes an ovmf file that
>> uses CRLF line endings, and plain git am corrupts the patch.
>>
>> I have also reported the underlying bugs upstream:
>>   llvm float16 fix, merged:
>>     https://github.com/llvm/llvm-project/pull/219675
>>   ovmf fix, sent to edk2:
>>     https://github.com/tianocore/edk2/pull/13038
>>   pango warning, the root cause is in GLib, reported to both:
>>     https://gitlab.gnome.org/GNOME/glib/-/issues/4038
>>     https://gitlab.gnome.org/GNOME/pango/-/issues/900
>>   vulkan-samples warning, which is a real bug in their code:
>>     https://github.com/KhronosGroup/Vulkan-Samples/issues/1570
>>
>> Tested: oe-selftest clang suites on qemuarm, qemuarm64, qemux86,
>> qemux86-64 and qemuriscv64 on the autobuilder, musl images on qemux86
>> and qemuarm64, a qemux86 world build with TOOLCHAIN=clang, 32-bit
>> multilib, and core-image-minimal testimage runs.
>>
>> Deepesh Varatharajan (2):
>>   rust: Fix build and oe-selftest failures with LLVM 23
>>   clang/llvm: Ignore tests fail with clang/llvm 23 upgrade
>>
>> Sunil Dora (9):
>>   clang/llvm: Upgrade to 23.1.0 release
>>   spirv-llvm-translator: Upgrade to 23.1.0
>>   openmp: Build via the LLVM runtimes entry point
>>   rust: Do not pass the removed x86 amx-tf32 feature to LLVM 23
>>   clang: Disable clangd's decision-forest completion model on powerpc
>>   pango: Don't turn clang 23's -Wunused-but-set-global into an error
>>   ovmf: Fix memcpy alias prototype for clang 23
>>   vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error
>>   gettext: Export a fully-flagged Objective-C compiler
>>
>>  meta/conf/distro/include/maintainers.inc      |   2 +-
>>  meta/lib/oeqa/selftest/cases/clang.py         |  10 +
>>  meta/lib/oeqa/selftest/cases/rust.py          |   1 +
>>  ...t-env.in-do-not-add-C-CXX-parameters.patch |  17 +-
>>  meta/recipes-core/gettext/gettext_1.0.bb      |   5 +
>>  ...sicLib-fix-memcpy-alias-prototype-fo.patch |  35 +
>>  meta/recipes-core/ovmf/ovmf_git.bb            |   1 +
>>  ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
>>  ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 --
>>  ...-support-a-new-embedded-linux-target.patch | 309 --------
>>  ...env-override-of-exe-and-libdir-path.patch} |   4 +-
>>  ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
>>  ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
>>  ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
>>  ...fine-releative-gcc-installation-dir.patch} |  10 +-
>>  ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
>>  ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
>>  ...ure-for-packages-using-find_package.patch} |  20 +-
>>  ...e-dir-location-for-cross-toolchains.patch} |   4 +-
>>  ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
>>  ...clang-Use-python3-in-python-scripts.patch} |   6 +-
>>  ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +-
>>  ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
>>  ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
>>  ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
>>  ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 --
>>  ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
>>  ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
>>  ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
>>  ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
>>  ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 +-
>>  ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
>>  ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
>>  ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
>>  ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
>>  ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
>>  ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
>>  ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
>>  ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
>>  ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
>>  ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
>>  ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
>>  ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
>>  ...> 0034-guard-clang-tools-extra-test.patch} |  47 +-
>>  ...ng-block-when-searching-for-noreturn.patch |  41 --
>>  ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 +
>>  ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 --------
>>  ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 -
>>  ...te-exit-fold-candidates-in-determini.patch |  71 --
>>  meta/recipes-devtools/clang/clang_git.bb      |   4 +
>>  meta/recipes-devtools/clang/common-clang.inc  |   4 +-
>>  meta/recipes-devtools/clang/common.inc        |  78 +--
>>  meta/recipes-devtools/clang/openmp_git.bb     |   5 +-
>>  ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
>>  ...llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch |  38 +
>>  meta/recipes-devtools/rust/rust-source.inc    |   2 +
>>  ...ror-on-clang-s-unused-but-set-global.patch |  28 +
>>  meta/recipes-graphics/pango/pango_1.58.0.bb   |   1 +
>>  ...1.5.bb => spirv-llvm-translator_23.1.0.bb} |   6 +-
>>  .../vulkan/vulkan-samples_git.bb              |   4 +-
>>  60 files changed, 1109 insertions(+), 1113 deletions(-)
>>  create mode 100644
>> meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch
>>  rename
>> meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
>> => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
>>  delete mode 100644
>> meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
>>  delete mode 100644
>> meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
>>  rename
>> meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
>> => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch
>> => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
>> => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch
>> => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch
>> => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
>> => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch
>> => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch
>> => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
>> => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
>> => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch
>> => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
>> => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
>> => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch
>> => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch
>> => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
>>  delete mode 100644
>> meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
>>  rename
>> meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch
>> => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
>> => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
>> => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
>> => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
>> => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
>> => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
>> => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
>> => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
>> => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
>> => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
>> => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
>> => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
>> => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
>> => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
>> => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
>> => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
>> => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
>>  rename
>> meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch
>> => 0034-guard-clang-tools-extra-test.patch} (83%)
>>  delete mode 100644
>> meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
>>  create mode 100644
>> meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
>>  delete mode 100644
>> meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
>>  delete mode 100644
>> meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
>>  delete mode 100644
>> meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
>>  create mode 100644
>> meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>>  create mode 100644
>> meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch
>>  create mode 100644
>> meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
>>  rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb =>
>> spirv-llvm-translator_23.1.0.bb} (87%)
>>
>> --
>> 2.43.0
>>
>>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#244697): https://lists.openembedded.org/g/openembedded-core/message/244697
> Mute This Topic: https://lists.openembedded.org/mt/120998127/8968818
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>
>
>

[-- Attachment #2: Type: text/html, Size: 19485 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 03/11] openmp: Build via the LLVM runtimes entry point
  2026-09-01  4:33     ` [OE-core] " Dora, Sunil Kumar
@ 2026-09-03  1:11       ` Khem Raj
  0 siblings, 0 replies; 30+ messages in thread
From: Khem Raj @ 2026-09-03  1:11 UTC (permalink / raw)
  To: Dora, Sunil Kumar
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 4062 bytes --]

On Mon, Aug 31, 2026 at 9:33 PM Dora, Sunil Kumar <
SunilKumar.Dora@windriver.com> wrote:

> On 8/31/2026 1:15 AM, Khem Raj via lists.openembedded.org wrote:
>
> *CAUTION: This email comes from a non Wind River email account!*
> Do not click links or open attachments unless you recognize the sender and
> know the content is safe.
>
>
> On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:
>
>> From: Sunil Dora <sunilkumar.dora@windriver.com>
>>
>> LLVM 23 removed the standalone build mode for openmp, so do_configure
>> fails with
>>
>>   The legacy standalone build mode has been removed
>>
>> Configure it through the runtimes build with LLVM_ENABLE_RUNTIMES=openmp,
>> the same way libcxx is built.
>>
>> The runtimes build reads LLVM_LIBDIR_SUFFIX; nothing in LLVM 23 reads
>> OPENMP_LIBDIR_SUFFIX any more, so pass the standard variable like the
>> other clang-family recipes do. Without it openmp installs into lib/
>> while a multilib configuration packages lib64/, and do_package fails
>> with "installed but not shipped" for libomp.so, libarcher.so,
>> libompd.so and the cmake files.
>>
>> Signed-off-by: Sunil Dora <sunilkumar.dora@windriver.com>
>> ---
>>  meta/recipes-devtools/clang/openmp_git.bb | 5 +++--
>>  1 file changed, 3 insertions(+), 2 deletions(-)
>>
>> diff --git a/meta/recipes-devtools/clang/openmp_git.bb
>> b/meta/recipes-devtools/clang/openmp_git.bb
>> index 2ba83d48c6..90d4911623 100644
>> --- a/meta/recipes-devtools/clang/openmp_git.bb
>> +++ b/meta/recipes-devtools/clang/openmp_git.bb
>> @@ -18,10 +18,11 @@ inherit cmake pkgconfig python3targetconfig
>>  DEPENDS += "elfutils libffi clang"
>>
>>  EXTRA_OECMAKE += "-DCMAKE_BUILD_TYPE=RelWithDebInfo \
>> -
>> -DOPENMP_LIBDIR_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \
>> +                  -DLLVM_ENABLE_RUNTIMES=openmp \
>> +                  -DLLVM_LIBDIR_SUFFIX=${LLVM_LIBDIR_SUFFIX} \
>>
>
>
>
> The recipe keeps PACKAGECONFIG ?= "ompt-tools offloading-plugin" — under
> the runtimes entry point, does offloading-plugin still do anything, or
> would it now need offload added to LLVM_ENABLE_RUNTIMES?
>
> It doesn't do anything for the build, and it didn't with the old entry
> point either. It passes no cmake flags and the build depends
> are already in DEPENDS. So the only thing it really adds is the
> libelf/libffi RDEPENDS. Our libomp.so links only libc.
> The plugins that needed libffi/libelf moved out of openmp/ into offload/
> back in LLVM 19, so nothing here builds them.
> The openmp-libomptarget package is empty, no ipk gets written.
>
> I only checked oe-core, other layers may still use this option, you know
> that history better than me.
>
> OPENMP_ENABLE_LIBOMPTARGET still works though. It adds some hooks in
> libomp that look up libomptarget functions with dlsym at runtime.
> Default is ON on 64-bit, the recipe doesn't touch it, and it is the same
> with both entry points.
>
> To actually build the plugins we would need
> LLVM_ENABLE_RUNTIMES="openmp;offload".
> That is a new library and new packaging, so I did not want to mix it into
> the upgrade.
>
> As a follow-up I can keep the PACKAGECONFIG as is, drop it with the empty
> package, or add offload as a new option.
> Which one do you prefer?
>

Latter is good to go IMO.


>
> Thanks,
> Sunil Dora
>
>
>
>>                "
>>
>> -OECMAKE_SOURCEPATH = "${S}/openmp"
>> +OECMAKE_SOURCEPATH = "${S}/runtimes"
>>
>>  PACKAGECONFIG ?= "ompt-tools offloading-plugin"
>>
>> --
>> 2.43.0
>>
>>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#244694): https://lists.openembedded.org/g/openembedded-core/message/244694
> Mute This Topic: https://lists.openembedded.org/mt/120998125/8968818
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>
>
>

[-- Attachment #2: Type: text/html, Size: 7259 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
  2026-09-03  1:10     ` Khem Raj
@ 2026-09-03 23:46       ` Khem Raj
  2026-09-04  4:49         ` Dora, Sunil Kumar
  0 siblings, 1 reply; 30+ messages in thread
From: Khem Raj @ 2026-09-03 23:46 UTC (permalink / raw)
  To: Dora, Sunil Kumar
  Cc: openembedded-core@lists.openembedded.org, MacLeod, Randy,
	Kokkonda, Sundeep, deepesh.vatharaj@windriver.com

[-- Attachment #1: Type: text/plain, Size: 16326 bytes --]

clang 23 is getting into an infinite loop compiling dovecot.

On Wed, Sep 2, 2026 at 6:10 PM Khem Raj <raj.khem@gmail.com> wrote:

>
>
> On Mon, Aug 31, 2026 at 9:59 PM Dora, Sunil Kumar <
> SunilKumar.Dora@windriver.com> wrote:
>
>> On 8/31/2026 1:23 AM, Khem Raj via lists.openembedded.org wrote:
>>
>> *CAUTION: This email comes from a non Wind River email account!*
>> Do not click links or open attachments unless you recognize the sender
>> and know the content is safe.
>> Looks pretty good to me. I have few feedback comments, not a merge
>> blocker but good to consider for future ease of porting.
>>
>> Thanks Khem.
>>
>> Quick update on the upstream side since the series went out.
>>
>> The clang half of the ssp_nonshared patch (0004 in the stack) was *merged
>> *into llvm main yesterday, commit fd974c429301
>> <https://github.com/llvm/llvm-project/commit/fd974c4293015388337e2f66f817a23e5873389f>,
>> reviewed by
>> MaskRay (Original PR #219828
>> <https://github.com/llvm/llvm-project/pull/219828> ). A backport to
>> release/23.x is open as PR #220136
>> <https://github.com/llvm/llvm-project/pull/220136>.
>> If that lands I will flip 0004 to Upstream-Status: Backport, and at the
>> next upgrade the patch goes away entirely.
>>
>
> Thanks for following up on these patches, its really long time that we
> clear this debt.
>
>
>>
>> The gcc half is on gcc-patches
>> <https://gcc.gnu.org/pipermail/gcc-patches/2026-August/729351.html> as
>> v2 with bugzilla PR 127138
>> <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=127138>. Sam James
>> mentioned Gentoo has carried the same fix downstream for years.
>>
>
> yes, I know, again same, it will be nicer to get this list down as well.
> Somethings are due to how OE has customized stuff so it will
> be hard to get rid of but anything that gets upstreamed is a bonus.
>
>
>>
>> Thanks,
>> Sunil Dora
>>
>>
>> On Sun, Aug 30, 2026 at 5:59 AM <sunilkumar.dora@windriver.com> wrote:
>>
>>> From: Sunil Dora <sunilkumar.dora@windriver.com>
>>>
>>> This upgrades clang/llvm from 22.1.8 to 23.1.0 and fixes the fallout
>>> found while testing the result.
>>>
>>> The carried LLVM patch stack goes from 41 to 35: seven dropped
>>> because 23.1.0 already contains the fix or the code they patched no
>>> longer exists, three reworked for LLVM 23, and one added for a 32-bit
>>> x86 build break, already merged in llvm-project.
>>>
>>> Please apply with git am --keep-cr: patch 8 fixes an ovmf file that
>>> uses CRLF line endings, and plain git am corrupts the patch.
>>>
>>> I have also reported the underlying bugs upstream:
>>>   llvm float16 fix, merged:
>>>     https://github.com/llvm/llvm-project/pull/219675
>>>   ovmf fix, sent to edk2:
>>>     https://github.com/tianocore/edk2/pull/13038
>>>   pango warning, the root cause is in GLib, reported to both:
>>>     https://gitlab.gnome.org/GNOME/glib/-/issues/4038
>>>     https://gitlab.gnome.org/GNOME/pango/-/issues/900
>>>   vulkan-samples warning, which is a real bug in their code:
>>>     https://github.com/KhronosGroup/Vulkan-Samples/issues/1570
>>>
>>> Tested: oe-selftest clang suites on qemuarm, qemuarm64, qemux86,
>>> qemux86-64 and qemuriscv64 on the autobuilder, musl images on qemux86
>>> and qemuarm64, a qemux86 world build with TOOLCHAIN=clang, 32-bit
>>> multilib, and core-image-minimal testimage runs.
>>>
>>> Deepesh Varatharajan (2):
>>>   rust: Fix build and oe-selftest failures with LLVM 23
>>>   clang/llvm: Ignore tests fail with clang/llvm 23 upgrade
>>>
>>> Sunil Dora (9):
>>>   clang/llvm: Upgrade to 23.1.0 release
>>>   spirv-llvm-translator: Upgrade to 23.1.0
>>>   openmp: Build via the LLVM runtimes entry point
>>>   rust: Do not pass the removed x86 amx-tf32 feature to LLVM 23
>>>   clang: Disable clangd's decision-forest completion model on powerpc
>>>   pango: Don't turn clang 23's -Wunused-but-set-global into an error
>>>   ovmf: Fix memcpy alias prototype for clang 23
>>>   vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error
>>>   gettext: Export a fully-flagged Objective-C compiler
>>>
>>>  meta/conf/distro/include/maintainers.inc      |   2 +-
>>>  meta/lib/oeqa/selftest/cases/clang.py         |  10 +
>>>  meta/lib/oeqa/selftest/cases/rust.py          |   1 +
>>>  ...t-env.in-do-not-add-C-CXX-parameters.patch |  17 +-
>>>  meta/recipes-core/gettext/gettext_1.0.bb      |   5 +
>>>  ...sicLib-fix-memcpy-alias-prototype-fo.patch |  35 +
>>>  meta/recipes-core/ovmf/ovmf_git.bb            |   1 +
>>>  ...ify-cross-compilation.-Don-t-use-na.patch} |   6 +-
>>>  ...ibunwind-headers-when-LIBCXXABI_LIBU.patch |  60 --
>>>  ...-support-a-new-embedded-linux-target.patch | 309 --------
>>>  ...env-override-of-exe-and-libdir-path.patch} |   4 +-
>>>  ...-driver-Check-sysroot-for-ldso-path.patch} |  14 +-
>>>  ...ools.cpp-Add-lssp_nonshared-on-musl.patch} |   6 +-
>>>  ...5-clang-Prepend-trailing-to-sysroot.patch} |  10 +-
>>>  ...fine-releative-gcc-installation-dir.patch} |  10 +-
>>>  ...d-and-ldl-along-with-lunwind-for-st.patch} |  10 +-
>>>  ...-Check-for-atomic-double-intrinsics.patch} |   4 +-
>>>  ...ure-for-packages-using-find_package.patch} |  20 +-
>>>  ...e-dir-location-for-cross-toolchains.patch} |   4 +-
>>>  ...dyld-prefix-when-checking-sysroot-f.patch} |  18 +-
>>>  ...clang-Use-python3-in-python-scripts.patch} |   6 +-
>>>  ...-anchor-for-adding-OE-distro-vendor.patch} |  37 +-
>>>  ...ple-for-non-debian-multiarch-linux-.patch} |   9 +-
>>>  ...ibunwind-Added-unw_backtrace-method.patch} |   8 +-
>>>  ...016-lldb-Link-with-libatomic-on-x86.patch} |   4 +-
>>>  ...ot-use-backtrace-APIs-on-non-glibc-l.patch |  68 --
>>>  ...mpiler-rt-Enable-__int128-for-ppc32.patch} |  26 +-
>>>  ...t-use-cmake-infra-to-detect-libzstd.patch} |   8 +-
>>>  ...-Fix-stat-struct-s-size-for-O32-ABI.patch} |   6 +-
>>>  ...cpp-ARMLibDirs-search-also-in-lib32.patch} |  10 +-
>>>  ...-OE-specific-ABI-triple-for-N32-ABI.patch} |  63 +-
>>>  ...nwind.pc.in-and-llvm-config-scripts.patch} |  12 +-
>>>  ...pect-LLVM_LIBDIR_SUFFIX-like-other-.patch} |  17 +-
>>>  ...o-not-pass-target-to-clang-compiler.patch} |   4 +-
>>>  ...-sort-ClassInfo-lists-by-name-as-we.patch} |   4 +-
>>>  ...ve-LLVM_LDFLAGS-from-ldflags-output.patch} |   4 +-
>>>  ...de-sync_fetch_and_-for-any-pre-ARMv.patch} |   6 +-
>>>  ...de-uptr-sptr-typedefs-on-Mips-Linux.patch} |   8 +-
>>>  ...-headers-in-the-debug-info-when-bui.patch} |   6 +-
>>>  ..._HAVE_OPT_VIEWER_MODULES-externally.patch} |   6 +-
>>>  ...ang-tblgen-if-it-is-actually-needed.patch} |   8 +-
>>>  ...ymlink-path-for-libcc-when-LLVM_ENA.patch} |   8 +-
>>>  ...ix-sysroot-based-compiler-rt-search.patch} |  15 +-
>>>  ...> 0034-guard-clang-tools-extra-test.patch} |  47 +-
>>>  ...ng-block-when-searching-for-noreturn.patch |  41 --
>>>  ...e-float16-on-32-bit-x86-without-SSE2.patch |  36 +
>>>  ...UNKNOWN-elements-of-OffloadArch-enum.patch | 274 --------
>>>  ...e-__gnu_unwind_frame-in-cxa_personal.patch |  33 -
>>>  ...te-exit-fold-candidates-in-determini.patch |  71 --
>>>  meta/recipes-devtools/clang/clang_git.bb      |   4 +
>>>  meta/recipes-devtools/clang/common-clang.inc  |   4 +-
>>>  meta/recipes-devtools/clang/common.inc        |  78 +--
>>>  meta/recipes-devtools/clang/openmp_git.bb     |   5 +-
>>>  ...ommits-from-rust-Fix-selftest-llvm23.patch | 661 ++++++++++++++++++
>>>  ...llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch |  38 +
>>>  meta/recipes-devtools/rust/rust-source.inc    |   2 +
>>>  ...ror-on-clang-s-unused-but-set-global.patch |  28 +
>>>  meta/recipes-graphics/pango/pango_1.58.0.bb   |   1 +
>>>  ...1.5.bb => spirv-llvm-translator_23.1.0.bb} |   6 +-
>>>  .../vulkan/vulkan-samples_git.bb              |   4 +-
>>>  60 files changed, 1109 insertions(+), 1113 deletions(-)
>>>  create mode 100644
>>> meta/recipes-core/ovmf/ovmf/0005-CryptoPkg-IntrinsicLib-fix-memcpy-alias-prototype-fo.patch
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0003-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch
>>> => 0001-compiler-rt-Simplify-cross-compilation.-Don-t-use-na.patch} (90%)
>>>  delete mode 100644
>>> meta/recipes-devtools/clang/clang/0001-libcxxabi-Find-libunwind-headers-when-LIBCXXABI_LIBU.patch
>>>  delete mode 100644
>>> meta/recipes-devtools/clang/clang/0002-compiler-rt-support-a-new-embedded-linux-target.patch
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0004-llvm-allow-env-override-of-exe-and-libdir-path.patch
>>> => 0002-llvm-allow-env-override-of-exe-and-libdir-path.patch} (96%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0005-clang-driver-Check-sysroot-for-ldso-path.patch
>>> => 0003-clang-driver-Check-sysroot-for-ldso-path.patch} (87%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0006-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch
>>> => 0004-clang-Driver-tools.cpp-Add-lssp_nonshared-on-musl.patch} (86%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0007-clang-Prepend-trailing-to-sysroot.patch
>>> => 0005-clang-Prepend-trailing-to-sysroot.patch} (81%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0009-clang-Define-releative-gcc-installation-dir.patch
>>> => 0006-clang-Define-releative-gcc-installation-dir.patch} (94%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0010-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch
>>> => 0007-clang-Add-lpthread-and-ldl-along-with-lunwind-for-st.patch} (86%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0011-Check-for-atomic-double-intrinsics.patch
>>> => 0008-Check-for-atomic-double-intrinsics.patch} (91%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0012-cmake-Fix-configure-for-packages-using-find_package.patch
>>> => 0009-cmake-Fix-configure-for-packages-using-find_package.patch} (89%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0013-clang-Fix-resource-dir-location-for-cross-toolchains.patch
>>> => 0010-clang-Fix-resource-dir-location-for-cross-toolchains.patch} (95%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0014-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch
>>> => 0011-clang-driver-Add-dyld-prefix-when-checking-sysroot-f.patch} (88%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0015-clang-Use-python3-in-python-scripts.patch
>>> => 0012-clang-Use-python3-in-python-scripts.patch} (90%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0016-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch
>>> => 0013-llvm-clang-Insert-anchor-for-adding-OE-distro-vendor.patch} (91%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0018-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch
>>> => 0014-clang-Fix-x86-triple-for-non-debian-multiarch-linux-.patch} (86%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0019-libunwind-Added-unw_backtrace-method.patch
>>> => 0015-libunwind-Added-unw_backtrace-method.patch} (89%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0020-lldb-Link-with-libatomic-on-x86.patch
>>> => 0016-lldb-Link-with-libatomic-on-x86.patch} (92%)
>>>  delete mode 100644
>>> meta/recipes-devtools/clang/clang/0017-compiler-rt-Do-not-use-backtrace-APIs-on-non-glibc-l.patch
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0021-compiler-rt-Enable-__int128-for-ppc32.patch
>>> => 0017-compiler-rt-Enable-__int128-for-ppc32.patch} (77%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0022-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch
>>> => 0018-llvm-Do-not-use-cmake-infra-to-detect-libzstd.patch} (91%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0023-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch
>>> => 0019-compiler-rt-Fix-stat-struct-s-size-for-O32-ABI.patch} (91%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0024-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch
>>> => 0020-ToolChains-Gnu.cpp-ARMLibDirs-search-also-in-lib32.patch} (98%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0025-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch
>>> => 0021-clang-llvm-Add-OE-specific-ABI-triple-for-N32-ABI.patch} (60%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0026-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch
>>> => 0022-llvm-Add-libunwind.pc.in-and-llvm-config-scripts.patch} (84%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0027-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch
>>> => 0023-scan-build-py-respect-LLVM_LIBDIR_SUFFIX-like-other-.patch} (90%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0028-compiler-rt-Do-not-pass-target-to-clang-compiler.patch
>>> => 0024-compiler-rt-Do-not-pass-target-to-clang-compiler.patch} (91%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0029-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch
>>> => 0025-AsmMatcherEmitter-sort-ClassInfo-lists-by-name-as-we.patch} (92%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0030-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch
>>> => 0026-llvm-config-remove-LLVM_LDFLAGS-from-ldflags-output.patch} (92%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0031-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch
>>> => 0027-compiler-rt-Exclude-sync_fetch_and_-for-any-pre-ARMv.patch} (95%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0032-compiler-rt-Hardcode-uptr-sptr-typedefs-on-Mips-Linu.patch
>>> => 0028-Hardcode-uptr-sptr-typedefs-on-Mips-Linux.patch} (86%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0034-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch
>>> => 0029-Revert-libc-Remap-headers-in-the-debug-info-when-bui.patch} (89%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0036-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch
>>> => 0030-Don-t-expose-LLVM_HAVE_OPT_VIEWER_MODULES-externally.patch} (86%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0037-clang-Only-build-clang-tblgen-if-it-is-actually-need.patch
>>> => 0031-Only-build-clang-tblgen-if-it-is-actually-needed.patch} (81%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0038-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch
>>> => 0032-llvm-libgcc-Fix-symlink-path-for-libcc-when-LLVM_ENA.patch} (93%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0041-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch
>>> => 0033-Consolidate-and-fix-sysroot-based-compiler-rt-search.patch} (91%)
>>>  rename
>>> meta/recipes-devtools/clang/clang/{0042-guard-clang-tools-extra-test.patch
>>> => 0034-guard-clang-tools-extra-test.patch} (83%)
>>>  delete mode 100644
>>> meta/recipes-devtools/clang/clang/0035-Prevent-revisiting-block-when-searching-for-noreturn.patch
>>>  create mode 100644
>>> meta/recipes-devtools/clang/clang/0035-libc-Disable-float16-on-32-bit-x86-without-SSE2.patch
>>>  delete mode 100644
>>> meta/recipes-devtools/clang/clang/0039-Rename-UNUSED-and-UNKNOWN-elements-of-OffloadArch-enum.patch
>>>  delete mode 100644
>>> meta/recipes-devtools/clang/clang/0040-libcxxabi-declare-__gnu_unwind_frame-in-cxa_personal.patch
>>>  delete mode 100644
>>> meta/recipes-devtools/clang/clang/0043-LoopUnroll-Iterate-exit-fold-candidates-in-determini.patch
>>>  create mode 100644
>>> meta/recipes-devtools/rust/files/0004-Backport-commits-from-rust-Fix-selftest-llvm23.patch
>>>  create mode 100644
>>> meta/recipes-devtools/rust/files/0005-rustc_codegen_llvm-Do-not-pass-amx-tf32-to-LLVM-23.patch
>>>  create mode 100644
>>> meta/recipes-graphics/pango/pango/0001-meson-don-t-error-on-clang-s-unused-but-set-global.patch
>>>  rename meta/recipes-graphics/spir/{spirv-llvm-translator_22.1.5.bb =>
>>> spirv-llvm-translator_23.1.0.bb} (87%)
>>>
>>> --
>>> 2.43.0
>>>
>>>
>> -=-=-=-=-=-=-=-=-=-=-=-
>> Links: You receive all messages sent to this group.
>> View/Reply Online (#244697): https://lists.openembedded.org/g/openembedded-core/message/244697
>> Mute This Topic: https://lists.openembedded.org/mt/120998127/8968818
>> Group Owner: openembedded-core+owner@lists.openembedded.org
>> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [SunilKumar.Dora@windriver.com]
>> -=-=-=-=-=-=-=-=-=-=-=-
>>
>>
>>
>>

[-- Attachment #2: Type: text/html, Size: 19915 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
  2026-09-03 23:46       ` Khem Raj
@ 2026-09-04  4:49         ` Dora, Sunil Kumar
  2026-09-05 13:26           ` Dora, Sunil Kumar
  0 siblings, 1 reply; 30+ messages in thread
From: Dora, Sunil Kumar @ 2026-09-04  4:49 UTC (permalink / raw)
  To: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 940 bytes --]

On Fri, Sep 4, 2026 at 05:17 AM, Khem Raj wrote:

> 
> clang 23 is getting into an infinite loop compiling dovecot.

I can reproduce it here. The file is src/lib-json/test-json-generator.c at -O2. clang 22 compiles it in
about 2 seconds, with clang 23 I gave up waiting after half an hour, so it does look hung.
The time is going into one of the loop optimization passes in the code generator.

Turning that pass off gets dovecot building again. The whole recipe
went through fine here on qemux86-64 with TOOLCHAIN=clang and

CFLAGS:append:pn-dovecot = " -mllvm -disable-lsr"

in local.conf. The option just disables the pass, so it should behave the same on other targets.
The affected file is only one of dovecot's own test binaries, nothing that gets shipped.

I am reducing a testcase and will report it to llvm, will post the link here.
If a fix lands I will request a release/23.x backport.

Thanks,
Sunil Dora

[-- Attachment #2: Type: text/html, Size: 1068 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
  2026-09-04  4:49         ` Dora, Sunil Kumar
@ 2026-09-05 13:26           ` Dora, Sunil Kumar
  2026-09-05 18:01             ` [OE-core] " Khem Raj
  0 siblings, 1 reply; 30+ messages in thread
From: Dora, Sunil Kumar @ 2026-09-05 13:26 UTC (permalink / raw)
  To: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 952 bytes --]

On Fri, Sep 4, 2026 at 10:19 AM, Dora, Sunil Kumar wrote:

> 
> I am reducing a testcase and will report it to llvm, will post the link
> here.
> If a fix lands I will request a release/23.x backport.

Hi Khem,

I bisected llvm between 22.1.8 and 23.1.0. The problem comes from the new DFAJumpThreading pass
which is on by default in clang 23. The full file takes more than 90 minutes where clang 22 needs about
2 seconds.

I reported it upstream with a reduced testcase:
https://github.com/llvm/llvm-project/issues/221391

There is also a better workaround than the -disable-lsr I posted earlier. Turning off just the new pass keeps
LSR and behaves the same as clang 22:

CFLAGS:append:toolchain-clang = " -mllvm -enable-dfa-jump-thread=false"

I sent this as v2 of your dovecot patch on openembedded-devel. Once the llvm fix lands I will ask for a
release/23.x backport, then we can drop the workaround.

Thanks,
Sunil Dora

[-- Attachment #2: Type: text/html, Size: 1079 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [OE-core] [PATCH 00/11] clang/llvm: Upgrade to 23.1.0
  2026-09-05 13:26           ` Dora, Sunil Kumar
@ 2026-09-05 18:01             ` Khem Raj
  0 siblings, 0 replies; 30+ messages in thread
From: Khem Raj @ 2026-09-05 18:01 UTC (permalink / raw)
  To: SunilKumar.Dora; +Cc: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 1660 bytes --]

On Sat, Sep 5, 2026 at 6:26 AM Dora, Sunil Kumar via lists.openembedded.org
<SunilKumar.Dora=windriver.com@lists.openembedded.org> wrote:

> On Fri, Sep 4, 2026 at 10:19 AM, Dora, Sunil Kumar wrote:
>
> I am reducing a testcase and will report it to llvm, will post the link
> here.
> If a fix lands I will request a release/23.x backport.
>
> Hi Khem,
>
> I bisected llvm between 22.1.8 and 23.1.0. The problem comes from the new
> DFAJumpThreading pass
> which is on by default in clang 23. The full file takes more than 90
> minutes where clang 22 needs about
> 2 seconds.
>
> I reported it upstream with a reduced testcase:
> https://github.com/llvm/llvm-project/issues/221391
>
> There is also a better workaround than the -disable-lsr I posted earlier.
> Turning off just the new pass keeps
> LSR and behaves the same as clang 22:
>
> CFLAGS:append:toolchain-clang = " -mllvm -enable-dfa-jump-thread=false"
>
> I sent this as v2 of your dovecot patch on openembedded-devel. Once the
> llvm fix lands I will ask for a
> release/23.x backport, then we can drop the workaround.
>

Thanks Sunil. this looks more targeted I will take v2.


>
> Thanks,
> Sunil Dora
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#245148):
> https://lists.openembedded.org/g/openembedded-core/message/245148
> Mute This Topic: https://lists.openembedded.org/mt/120998127/1997914
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [
> raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>

[-- Attachment #2: Type: text/html, Size: 2817 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2026-09-05 18:02 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-30 12:58 [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 sunilkumar.dora
2026-08-30 12:58 ` [PATCH 01/11] clang/llvm: Upgrade to 23.1.0 release sunilkumar.dora
2026-08-30 19:53   ` Khem Raj
2026-09-01  3:37     ` [OE-core] " Dora, Sunil Kumar
2026-09-01 12:49       ` Richard Purdie
2026-08-30 12:58 ` [PATCH 02/11] spirv-llvm-translator: Upgrade to 23.1.0 sunilkumar.dora
2026-08-30 19:43   ` Khem Raj
2026-09-01  4:07     ` [OE-core] " Dora, Sunil Kumar
2026-08-30 12:58 ` [PATCH 03/11] openmp: Build via the LLVM runtimes entry point sunilkumar.dora
2026-08-30 19:45   ` Khem Raj
2026-09-01  4:33     ` [OE-core] " Dora, Sunil Kumar
2026-09-03  1:11       ` Khem Raj
2026-08-30 12:58 ` [PATCH 04/11] rust: Fix build and oe-selftest failures with LLVM 23 sunilkumar.dora
2026-08-30 19:47   ` Khem Raj
2026-09-01  5:17     ` [OE-core] " Dora, Sunil Kumar
2026-09-03  1:08       ` Khem Raj
2026-08-30 12:58 ` [PATCH 05/11] rust: Do not pass the removed x86 amx-tf32 feature to " sunilkumar.dora
2026-08-30 12:58 ` [PATCH 06/11] clang: Disable clangd's decision-forest completion model on powerpc sunilkumar.dora
2026-08-30 12:58 ` [PATCH 07/11] pango: Don't turn clang 23's -Wunused-but-set-global into an error sunilkumar.dora
2026-08-30 12:58 ` [PATCH 08/11] ovmf: Fix memcpy alias prototype for clang 23 sunilkumar.dora
2026-08-30 12:58 ` [PATCH 09/11] vulkan-samples: Don't turn clang 23's -Wdangling-gsl into an error sunilkumar.dora
2026-08-30 12:58 ` [PATCH 10/11] gettext: Export a fully-flagged Objective-C compiler sunilkumar.dora
2026-08-30 12:58 ` [PATCH 11/11] clang/llvm: Ignore tests fail with clang/llvm 23 upgrade sunilkumar.dora
2026-08-30 19:53 ` [PATCH 00/11] clang/llvm: Upgrade to 23.1.0 Khem Raj
2026-09-01  4:59   ` [OE-core] " Dora, Sunil Kumar
2026-09-03  1:10     ` Khem Raj
2026-09-03 23:46       ` Khem Raj
2026-09-04  4:49         ` Dora, Sunil Kumar
2026-09-05 13:26           ` Dora, Sunil Kumar
2026-09-05 18:01             ` [OE-core] " Khem Raj

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.