diff --git a/0005-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch b/0005-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch new file mode 100644 index 0000000000000000000000000000000000000000..6baeba211638794a05e5e0533ae5228faa13f0d2 --- /dev/null +++ b/0005-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch @@ -0,0 +1,39 @@ +From e852d4cf3cafaabf907daf225ad32c3cc4d853f1 Mon Sep 17 00:00:00 2001 +From: liyunfei +Date: Thu, 28 Aug 2025 20:42:49 +0800 +Subject: [PATCH] [Propeller] bugfix for MachineBasicBlock hush set + +In some testcases x86 codegen might gen MBB with no BBID. Set hash for +these MBB will cause assertion fail. +--- + llvm/include/llvm/CodeGen/MachineBasicBlock.h | 11 +++++++++-- + 1 file changed, 9 insertions(+), 2 deletions(-) + +diff --git a/llvm/include/llvm/CodeGen/MachineBasicBlock.h b/llvm/include/llvm/CodeGen/MachineBasicBlock.h +index 51660e4ded13..b8789cd5afd4 100644 +--- a/llvm/include/llvm/CodeGen/MachineBasicBlock.h ++++ b/llvm/include/llvm/CodeGen/MachineBasicBlock.h +@@ -667,12 +667,19 @@ public: + + std::optional getBBID() const { return BBID; } + +- uint64_t getHash() const { return BBID->Hash; } ++ uint64_t getHash() const { ++ if (BBID) ++ return BBID->Hash; ++ return 0; ++ } + + /// Returns the section ID of this basic block. + MBBSectionID getSectionID() const { return SectionID; } + +- void setHash(uint64_t Hash) { BBID->Hash = Hash; } ++ void setHash(uint64_t Hash) { ++ if (BBID) ++ BBID->Hash = Hash; ++ } + + /// Sets the fixed BBID of this basic block. + void setBBID(const UniqueBBID &V) { +-- +Gitee diff --git a/llvm-for-oE-17.0.6-2506.0.4.tar.gz b/llvm-for-oE-17.0.6-2509.0.2.tar.gz similarity index 31% rename from llvm-for-oE-17.0.6-2506.0.4.tar.gz rename to llvm-for-oE-17.0.6-2509.0.2.tar.gz index 171f896de39b0f6dac45da2dda89362360f79b53..4109f4bcc611b4e31fc558db06308246d42bdb96 100644 --- a/llvm-for-oE-17.0.6-2506.0.4.tar.gz +++ b/llvm-for-oE-17.0.6-2509.0.2.tar.gz @@ -1,3 +1,3 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:db05405706279885e543dd562d7f2887fd433eb10dae819811df7d588e8548b3 -size 212541296 +version https://git-lfs.github.com/spec/v1 +oid sha256:717518c4ddf31b5d141fce1bdac7ede96a59de292f09f72482277ca0a49f489b +size 212666397 \ No newline at end of file diff --git a/llvm-toolset-17.spec b/llvm-toolset-17.spec index 81d5691267402e4d847aa2f2d31a7fc7d5eb685a..3f64e76069723e82fde4eebb9c50071b4213c294 100644 --- a/llvm-toolset-17.spec +++ b/llvm-toolset-17.spec @@ -9,11 +9,7 @@ # Build sys_llvm packages or compat packages %bcond_with sys_llvm %bcond_with check -%if %{os_version} == 2203 -%bcond_with toolchain_clang -%else %bcond_without toolchain_clang -%endif # mlir requires pybind11-2.9 but 22.03 only have pybind11-2.8 %if %{os_version} <= 2203 @@ -30,7 +26,7 @@ %undefine __cmake_in_source_build -%global src_tarball llvm-for-oE-17.0.6-2506.0.4 +%global src_tarball llvm-for-oE-17.0.6-2509.0.2 %global src_tarball_dir llvm-project-%{src_tarball} #region LLVM globals @@ -150,7 +146,7 @@ #region main package Name: llvm-toolset-%{maj_ver} Version: %{maj_ver}.%{min_ver}.%{patch_ver} -Release: 10 +Release: 11 Summary: The Low Level Virtual Machine License: NCSA @@ -169,6 +165,7 @@ Patch0003: 0003-fedora-standalone.patch %if %{os_version} <= 2003 Patch0004: 0004-remove-cmake_minimum_required.patch %endif +Patch0005: 0005-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch BuildRequires: gcc BuildRequires: gcc-c++ @@ -2776,6 +2773,11 @@ fi #endregion files %changelog +* Fri Oct 17 2025 liyunfei - 17.0.6-11 +- update to llvm-for-oe-17.0.6-2509.0.2 +- release-note https://gitee.com/openeuler/llvm-project/releases/tag/llvm-for-oE-17.0.6-2509.0.2 +- add fix for Propeller MachineBasicBlock hash set + * Tue Jul 01 2025 Wang Qiang - 17.0.6-10 - Replaced the hardcoded /opt/openEuler path with /opt/\%{_vendor}