diff --git a/0008-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch b/0008-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch new file mode 100644 index 0000000000000000000000000000000000000000..e91b8c404a7e25ca4652e25850c16194218cd0f3 --- /dev/null +++ b/0008-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch @@ -0,0 +1,15 @@ +diff --git a/llvm/lib/CodeGen/BasicBlockSections.cpp b/llvm/lib/CodeGen/BasicBlockSections.cpp +index 9b985f9f0aff..6e58c8fb2946 100644 +--- a/llvm/lib/CodeGen/BasicBlockSections.cpp ++++ b/llvm/lib/CodeGen/BasicBlockSections.cpp +@@ -319,7 +319,8 @@ void computeBBHash(MachineFunction &MF) { + } + } + } +- MBB.setHash(Hash); ++ if (MBB.getBBID()) ++ MBB.setHash(Hash); + } + } + +-- \ No newline at end of file diff --git a/llvm-for-oE-17.0.6-2506.0.4.tar.gz b/llvm-for-oE-17.0.6-2509.0.1.tar.gz similarity index 32% rename from llvm-for-oE-17.0.6-2506.0.4.tar.gz rename to llvm-for-oE-17.0.6-2509.0.1.tar.gz index 171f896de39b0f6dac45da2dda89362360f79b53..df9aef5c5ba96d6b6c1b13397801837eac539d25 100644 --- a/llvm-for-oE-17.0.6-2506.0.4.tar.gz +++ b/llvm-for-oE-17.0.6-2509.0.1.tar.gz @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:db05405706279885e543dd562d7f2887fd433eb10dae819811df7d588e8548b3 -size 212541296 +oid sha256:3437c2ca8c6e2fc0083e3db05e884bd5cd2c124ba51b902a8cb2e5bb13312a04 +size 212672038 diff --git a/llvm.spec b/llvm.spec index 6df284239ef09a7f420744d766f51c7ad8cf2f47..94110be7e21e974f07eee54745c242b18fbeb58d 100644 --- a/llvm.spec +++ b/llvm.spec @@ -6,6 +6,10 @@ %global os_version %{lua: print(tonumber(rpm.expand("%{dist}"):match("oe(%d+)") or 9999))} +%if %{os_version} == 1 +%global os_version 9999 +%endif + # Build sys_llvm packages or compat packages %bcond_without sys_llvm %bcond_without check @@ -28,7 +32,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.1 %global src_tarball_dir llvm-project-%{src_tarball} #region LLVM globals @@ -100,8 +104,6 @@ %global pkg_name_compiler_rt %{?scl_prefix}compiler-rt -%global optflags %(echo %{optflags} | sed 's/-fgcc-compatible//') -%global optflags %(echo %{optflags} | sed 's/-specs=\/usr\/lib\/rpm\/generic-hardened-cc1//') %ifnarch x86_64 %global optflags %(echo %{optflags} | sed 's/-fstack-clash-protection//') # may affect cmake check for fpic @@ -152,7 +154,7 @@ Name: llvm Name: llvm-toolset-%{maj_ver} %endif Version: %{maj_ver}.%{min_ver}.%{patch_ver} -Release: 47 +Release: 49 Summary: The Low Level Virtual Machine License: NCSA @@ -176,6 +178,7 @@ Patch0005: 0005-Fix-for-building-autotuner-with-mlir.patch %endif Patch0006: 0006-backport-mlir-Make-it-possible-to-build-a-DenseResou.patch Patch0007: 0007-backport-mlir-Add-Python-bindings-for-DenseResourceE.patch +Patch0008: 0008-Propeller-bugfix-for-MachineBasicBlock-hash-set.patch BuildRequires: gcc BuildRequires: gcc-c++ @@ -800,9 +803,6 @@ Documentation for LLVM libunwind %global runtimes %{runtimes};libcxx;libcxxabi;libunwind %endif -# Copy CFLAGS into ASMFLAGS, so -fcf-protection is used when compiling assembly files. -export ASMFLAGS="%{build_cflags}" - # We set CLANG_DEFAULT_PIE_ON_LINUX=OFF and PPC_LINUX_DEFAULT_IEEELONGDOUBLE=ON to match the # defaults used by Fedora's GCC. @@ -1018,6 +1018,11 @@ export ASMFLAGS="%{build_cflags}" extra_cmake_args='' #endregion cmake options +# set flags for build +export CFLAGS="%{build_cflags}" +export CXXFLAGS="%{build_cxxflags}" +export ASMFLAGS="%{build_cflags}" + %if %{with ACPO} echo "enable ACPO" export CFLAGS="-Wp,-DENABLE_ACPO ${CFLAGS}" @@ -1662,7 +1667,7 @@ reset_test_opts #region Test LLVM reset_test_opts # Xfail testing of update utility tools -export LIT_XFAIL="tools/UpdateTestChecks" +export LIT_XFAIL="tools/UpdateTestChecks;CodeGen/Hexagon/loop-prefetch.ll" %build_tool %cmake_target_opts check-llvm #endregion Test LLVM @@ -2881,6 +2886,13 @@ fi #endregion files %changelog +* Wed Aug 27 2025 liyunfei - 17.0.6-49 +- update to llvm-for-oe-17.0.6-2509.0.1 +- release-note https://gitee.com/openeuler/llvm-project/releases/tag/llvm-for-oE-17.0.6-2509.0.1 + +* Wed Aug 20 2025 liyunfei - 17.0.6-48 +- fix missing hardening compiler options + * Tue Jul 01 2025 liyunfei - 17.0.6-47 - fix for mlir build failure after numpy 2.3.0