Compare commits

...

71 Commits

Author SHA1 Message Date
David Abdurachmanov bbe4d4eaaf
Add support for riscv64
Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
2023-11-02 12:26:24 +02:00
David Abdurachmanov f3c9dc32ea
Merge remote-tracking branch 'up/main' into main-riscv64
Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
2023-11-02 12:20:45 +02:00
Tulio Magno Quites Machado Filho 4689129188 Update to LLVM 17.0.4 2023-10-31 18:00:16 -03:00
Yaakov Selkowitz 1b6d3f3740 Fix ld.so.conf.d path
This location is hard-coded by glibc and is not prefix-variable.  This
fixes flatpak app RPM builds of clang15 and packages dependent thereon
(e.g. openshadinglanguage).  Flatpaks using these packages will still
need to define LD_LIBRARY_PATH.
2023-10-19 09:13:26 -03:00
Tulio Magno Quites Machado Filho 5197c0ae27 Update to LLVM 17.0.3 2023-10-17 14:42:39 -03:00
Tulio Magno Quites Machado Filho 83e53f80ee Update to LLVM 17.0.2 2023-10-03 18:15:50 -03:00
Tulio Magno Quites Machado Filho 1e5009d192 Update to LLVM 17.0.1 2023-09-22 15:40:38 -03:00
Nikita Popov d71a6d614a Unset LLVM_VERSION_SUFFIX for compat builds as well
This is needed if the compat build is produced for an rc version,
which I'm currently trying to do to fix snapshot builds.

I don't see a reason why this bit should be omitted for snapshot
builds.
2023-09-14 15:04:17 +02:00
Nikita Popov 2b59cd5563 Re-enable ppc64 gold test
https://bugzilla.redhat.com/show_bug.cgi?id=2234396 has been fixed.
2023-09-14 07:50:09 +02:00
Tulio Magno Quites Machado Filho d007916e9b Update to LLVM 17.0.0 RC4 2023-09-09 09:08:09 -03:00
Yaakov Selkowitz 4e6a7e3ffb Update RHEL docs patch 2023-09-01 12:26:36 -04:00
Tulio Magno Quites Machado Filho de70be4496 Update to LLVM 17.0.0 RC3 2023-08-24 07:26:59 -03:00
Tulio Magno Quites Machado Filho bf19c70bc0 Temporarily disable a failing test on ppc64le
ld.gold is crashing with an internal error.
Disable this test temporarily while the issue is being investigated and
fixed.
2023-08-24 06:42:02 -03:00
Tulio Magno Quites Machado Filho b7b35dbbdc Update to LLVM 17.0.0 RC2 2023-08-23 07:30:44 -03:00
Tulio Magno Quites Machado Filho c7a62f31ea Disable LTO on i686
We're reaching a memory limit while linking libLLVM.so .
2023-08-17 15:18:16 -03:00
Tulio Magno Quites Machado Filho 15eacb3329 Apply rhel-specific patch on snapshot builds
Despite not testing on snapshot builds on RHEL, it's a good practice to
have the code ready for that.
2023-08-16 13:55:23 -03:00
Tulio Magno Quites Machado Filho cb1bdb3739 Re-add patch removed by mistake
Fixes: d5b39fd081 ("Update to LLVM 17.0.0 RC1")
2023-08-14 18:40:54 -03:00
Tulio Magno Quites Machado Filho 2ec945401e Enable LLVM_UNREACHABLE_OPTIMIZE temporarily
This has been causing issues when building clang.  Enable it temporarily
until the root cause is found and fixed.
2023-08-09 11:54:46 -03:00
Tulio Magno Quites Machado Filho d5b39fd081 Update to LLVM 17.0.0 RC1
This is also a squashed merge commit from upstream-snapshot (commit ID
340b9e8ea37dcbca) into rawhide whose most important commits from
upstream-snapshot are:

Konrad Kleine (50):
      Prepare for snapshot build
      Fix RPM build errors: File not found: /builddir/build/BUILDROOT/llvm-14.0.0~pre20211103.g1febf42f03f664-1.fc34.x86_64/usr/lib64/libLLVM-14.so
      Added back patch file
      Rebased with new patches from rawhide that weren't yet in the streamline branch
      Fix RPM build errors: File not found: /builddir/build/BUILDROOT/llvm-14.0.0~pre20211103.g1febf42f03f664-1.fc34.x86_64/usr/lib64/libLLVM-14.so
      Disable LTO for anything older than Fedora 34
      Use llvm_snapshot_version_suffix
      Remove patch for https://reviews.llvm.org/D108332 which is already upstream
      Only package cmake-devel when building a snapshot package and when NOT building in compat mode
      Fix RPM build
      Fix Macro expanded in comment on line 586: %{_libdir}/libLLVM-%{maj_ver}
      Fix rpm build warning/error: absolute symlink
      Default to DWARF4
      Merge remote-tracking branch 'upstream/rawhide' into upstream-snapshot
      Rebased patched on pagure/streamline
      Merge remote-tracking branch 'upstream/rawhide' into upstream-snapshot
      Added 0004-PATCH-clang-Revert-cmake-Don-t-install-plugins-used-.patch
      Revert "Added 0004-PATCH-clang-Revert-cmake-Don-t-install-plugins-used-.patch"
      Workaround linker error: memory exhausted
      Merge remote-tracking branch 'upstream/rawhide' into upstream-snapshot
      Added pgo_instrumented_build cmake args
      Fix /usr/bin/ld: cannot find /usr/lib64/clang/13.0.0/lib/linux/libclang_rt.profile-x86_64.a: No such file or directory
      Move bcond in cmake down in case we want to override stuff
      Make llvm use the llvm-snapshot-builder as well
      Use %{llvm_snapshot_extra_source_tags} macro
      Merge remote-tracking branch 'upstream/rawhide' into upstream-snapshot
      Merge remote-tracking branch 'upstream/rawhide' into upstream-snapshot
      Patch renewal from rebased llvm-project pagure/streamline branch
      Try to lock llvm* and clang* packages so that we don't install LLVM from a previous copr build
      Revert "Try to lock llvm* and clang* packages so that we don't install LLVM from a previous copr build"
      Rebase onto pagure/main
      Merge remote-tracking branch 'upstream/rawhide' into upstream-snapshot
      use llvm+cmake tarballs instead of big llvm-project and close unclosed %if
      Fixup: clang->cmake
      Move globals down for them to be expanded correctly
      Fix merge issue with patch
      Test without some patches
      Compiles and installs again
      Adapt to standalone third-party dir
      bring back files to llvm-googletest package
      fixing path to unittest
      Manually add https://reviews.llvm.org/D137890
      Add missing patch files
      Apply patchfiles independently for llvm and third-party dir
      List third-party gmock/gtest files in install
      Merge remote-tracking branch 'origin/rawhide' into upstream-snapshot
      Re-enable patches for gtest
      Disable LTO to speed up builds
      Added libLLVMTestingAnnotations.a to googletest subpackage
      Merge remote-tracking branch 'origin/rawhide' into upstream-snapshot

Nikita Popov (1):
      Sync with rawhide

Tom Stellard (13):
      Add patch to fix some lit test failures
      Revert "Add patch to fix some lit test failures"
      Add a patch from main branch to fix some lit tests
      Revert "Add a patch from main branch to fix some lit tests"
      Remove patch applied upstream
      Remove another upstreamed patch
      Add llvm-googletest dependency to llvm-devel
      Add JITLink patch to fix clang failures on aarch64 with libgcc-13
      Revert "Add JITLink patch to fix clang failures on aarch64 with libgcc-13"
      Fix a test failure on s390x
      Revert "Fix a test failure on s390x"
      copr: Install llvm-snapshot-builder from the local COPR project
      Sync with rawhide

sergesanspaille (1):
      Rebase downstream patches
2023-08-09 11:54:07 -03:00
Nikita Popov 5e22fb4ab6 Don't drop LDFLAGS for shared libraries
From the corresponding c9s fix:
b758d604f4
2023-08-08 16:51:16 +02:00
Tulio Magno Quites Machado Filho d180d56a78 Remove pkg_bindir and pkg_libdir
Replace them witn install_bindir and install_libdir respectively.
2023-08-03 19:30:40 +00:00
Tulio Magno Quites Machado Filho b5d6c1ccf0 Simplify a few %files entries
This is also deduplicating a small list of %files entries by replacing
the variable used to build their path.
2023-08-03 19:30:40 +00:00
Nikita Popov 2abc096557 Use build_cflags when setting ASMFLAGS
While the current implementation works on Fedora, on c9s/rhel
the CFLAGS haven't been set at this point yet, so we are missing
the -fcfprotection flag in ASMFLAGS. Using build_cflags avoids
this ordering problem.

Additionally, add -Wl,-z,cet-report=error to the libLLVM.so linker
flags, so we can detect such issues earlier in the future.
2023-08-03 19:29:38 +00:00
Tulio Magno Quites Machado Filho dd44fc12ea Fix rhbz #2224885 2023-07-31 17:19:01 -03:00
Fedora Release Engineering f9f0fb07de Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-20 12:55:16 +00:00
Tulio Magno Quites Machado Filho f9133b98bb Bump the release version 2023-07-10 18:38:50 -03:00
Nikita Popov bdb4929ebd Use LLVM_UNITTEST_LINK_FLAGS to reduce link times for unit tests
We currently spend a lot of time performing LTO on unit tests,
which is largely wasted effort. We can't disable LTO entirely,
because we don't have fat objects, but at least we can disable
post-link optimization.

For my local build, this reduces time in %build by about 30%.
2023-07-07 07:20:18 +00:00
Tulio Magno Quites Machado Filho cd99de7d35 Improve clang assembler error messages on s390x (rhbz#2216906)
Backport a patch from LLVM 17 that improves error messages from the
Clang assembler on s390x.

Also, disable LLVM_UNREACHABLE_OPTIMIZE in order to improve error
messages when llvm_unreachable() is called. There are many cases where
llvm_unreachable() is used as a error reporting function instead of the
recommended replacement for assert().

Fixes rhbz#2216906.
2023-07-03 15:09:05 -03:00
Tulio Magno Quites Machado Filho 61b03e8d59 Update to LLVM 16.0.6 2023-06-15 07:41:00 -03:00
Nikita Popov 236eac9d27 Split off llvm-cmake-utils package 2023-06-15 08:58:02 +02:00
Tulio Magno Quites Machado Filho ba5f101283 Update to LLVM 16.0.5 2023-06-05 14:26:35 -03:00
Yaakov Selkowitz bcf7ece4a8 Avoid recommonmark dependency in RHEL builds
python-recommonmark and its dependencies are unwanted in RHEL.
2023-05-22 11:57:51 -04:00
Tulio Magno Quites Machado Filho 85d29458f2 Update to LLVM 16.0.4 2023-05-18 21:54:20 -03:00
Tulio Magno Quites Machado Filho f98e61f997 Update to LLVM 16.0.3 2023-05-09 17:54:23 -03:00
Tulio Magno Quites Machado Filho 193ba1355d Update to LLVM 16.0.2 2023-04-25 17:19:37 -03:00
Nikita Popov 96037cf8ba Remove unused sources 2023-04-14 17:22:13 +02:00
Tulio Magno Quites Machado Filho 072d2198fb Update to LLVM 16.0.1 2023-04-12 17:39:44 +00:00
Jan200101 f51436a734
Stop installing gtest on compat builds 2023-04-12 14:13:53 +02:00
Tulio Magno Quites Machado Filho a4982d84f3 Stop distributing /usr/share/llvm/src/utils 2023-03-24 09:07:18 -03:00
Tulio Magno Quites Machado Filho a13a3551eb Distribute libllvm_gtest.a and libllvm_gtest_main.a with llvm-googletest 2023-03-24 09:04:53 -03:00
Tulio Magno Quites Machado Filho 0cd1abca26 Update to LLVM 16.0.0 2023-03-20 17:04:41 -03:00
Tulio Magno Quites Machado Filho 2f72d026a3 Fix the ppc64le triple 2023-03-16 22:07:43 -03:00
Tulio Magno Quites Machado Filho 59d2543cca Update the sources file 2023-03-15 09:06:18 -03:00
Tulio Magno Quites Machado Filho cc36c0869b Update to LLVM 16.0.0 RC4 2023-03-15 08:41:45 -03:00
Tulio Magno Quites Machado Filho 55d7730bb8 Fix llvm-exegesis failures on s390x 2023-03-15 08:41:45 -03:00
Tulio Magno Quites Machado Filho 3c4fee7794 Update to LLVM 16.0.0 RC3 2023-03-15 08:41:35 -03:00
Tulio Magno Quites Machado Filho 7f47caed9c Improve .gitignore
Replace many lines with a few with globs.
Add more entries in order to avoid adding files by mistake.
2023-02-16 16:43:01 -03:00
Tulio Magno Quites Machado Filho 780d2fc116 Remove unnecessary files
These files stopped being used in 2016 and are not necessary anymore.
2023-02-16 16:40:07 -03:00
Tulio Magno Quites Machado Filho a2100f44b7 Update to LLVM 16.0.0 RC1 2023-02-10 11:58:04 -03:00
Tulio Magno Quites Machado Filho 034719a43e Add the third-party source code 2023-02-01 18:49:54 -03:00
Konrad Kleine 3aef850832 Added libLLVMTestingAnnotations.a to googletest subpackage
See 3432f4bf86
2023-02-01 18:49:54 -03:00
Konrad Kleine c2901f71cb List third-party gmock/gtest files in install 2023-02-01 18:48:11 -03:00
Konrad Kleine 87fcbdde75 Manually add https://reviews.llvm.org/D137890 2023-02-01 18:48:11 -03:00
Konrad Kleine 9812a7f1ae bring back files to llvm-googletest package 2023-02-01 18:48:11 -03:00
Konrad Kleine c31ffc7ed1 Adapt to standalone third-party dir 2023-02-01 18:48:11 -03:00
Tulio Magno Quites Machado Filho b173c6109a Adopt SPDX identifiers in license
Also make it clear that Apache 2.0 with LLVM exceptions was adopted in
2019.
2023-01-19 16:45:58 -03:00
Fedora Release Engineering c92743ab8a Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-19 18:09:55 +00:00
Nikita Popov a20957b5eb Update to LLVM 15.0.7 2023-01-12 10:31:52 +01:00
Tom Stellard f543860321 Omit frame pointers when building 2023-01-09 20:33:24 +00:00
Nikita Popov 1862c052da Remove workaround for rbhz#2048440
It looks like this test passes now.
2022-12-19 16:35:33 +01:00
Timm Bäder 1d9fedd416 Enable LTO builds on s390x again
The PCRE limit problem has been fixed in redhat-rpm-config in
25ea080503?branch=rawhide
2022-12-05 17:07:40 +01:00
Nikita Popov 2fa672b23f Update to LLVM 15.0.6 2022-12-05 08:56:31 +01:00
Jan200101 920a8b1b56 Install cmake modules for compat builds 2022-11-15 09:40:45 +00:00
Nikita Popov 8e1f53d786 Copy CFLAGS to ASMFLAGs to enable CET in asm files 2022-11-11 10:23:47 +01:00
Nikita Popov 3c595192e2 Update to LLVM 15.0.4 2022-11-03 12:56:08 +01:00
Nikita Popov 0c4aa4a13c Remove abi_revision handling
We now longer ship rcs outside of copr, so this is no needed anymore.
2022-09-29 10:47:28 +00:00
Nikita Popov 6c4af9abec Drop GetHostTriple export again
This doesn't work by itself due to the config.guess dependency,
and I'm not longer sure this is the right approach. The runtimes
build should really be getting this from the exported
LLVM_HOST_TRIPLE variable.
2022-09-29 10:20:54 +02:00
Nikita Popov aec99db3ed Export GetHostTriple.cmake 2022-09-27 12:57:56 +02:00
Jesus Checa Hidalgo 2ce66b7035 Migrate tests to tests/llvm repo 2022-09-19 14:28:26 +00:00
Nikita Popov 5f0a6388b3 Fix compat build symlinks
Backport from llvm14 package.
2022-09-13 18:04:18 +02:00
Nikita Popov 81e2995efc Update to LLVM 15.0.0 2022-09-06 10:01:30 +02:00
31 changed files with 501 additions and 695 deletions

17
.copr/Makefile Normal file
View File

@ -0,0 +1,17 @@
# See https://docs.pagure.org/copr.copr/user_documentation.html#make-srpm
# See for the --setopt option in the enabling of copr repo see:
# https://pagure.io/copr/copr/issue/184
COPR_USERNAME=$(shell rpm --eval %copr_username)
COPR_PROJECT=$(shell rpm --eval %copr_projectname)
.PHONY: srpm
srpm:
dnf install -y dnf-plugins-core fedora-packager
dnf copr enable -y --setopt=reposdir=/tmp/yum.repos.d $(COPR_USERNAME)/$(COPR_PROJECT)
dnf install -y --setopt=reposdir=/tmp/yum.repos.d llvm-snapshot-builder
rpmbuild \
--define "_srcrpmdir $(outdir)" \
--define "_sourcedir $(shell pwd)" \
--define "_disable_source_fetch 0" \
-bs $(spec)

139
.gitignore vendored
View File

@ -1,132 +1,7 @@
/cfe-*.src.tar.gz
/compiler-rt-*.src.tar.gz
/lldb-*.src.tar.gz
/llvm-*.src.tar.gz
/clang-3.4.src.tar.gz
/cfe-3.5.0.src.tar.xz
/compiler-rt-3.5.0.src.tar.xz
/lldb-3.5.0.src.tar.xz
/llvm-3.5.0.src.tar.xz
/cfe-3.6.0.src.tar.xz
/compiler-rt-3.6.0.src.tar.xz
/lldb-3.6.0.src.tar.xz
/llvm-3.6.0.src.tar.xz
/llvm-3.6.1.src.tar.xz
/compiler-rt-3.6.1.src.tar.xz
/cfe-3.6.1.src.tar.xz
/lldb-3.6.1.src.tar.xz
/cfe-3.6.2.src.tar.xz
/compiler-rt-3.6.2.src.tar.xz
/lldb-3.6.2.src.tar.xz
/llvm-3.6.2.src.tar.xz
/llvm-3.7.0.src.tar.xz
/cfe-3.7.0.src.tar.xz
/compiler-rt-3.7.0.src.tar.xz
/lldb-3.7.0.src.tar.xz
/llvm-3.7.1.src.tar.xz
/llvm-3.8.0rc2.src.tar.xz
/llvm-3.8.0rc3.src.tar.xz
/llvm-3.8.0.src.tar.xz
/llvm-3.8.1.src.tar.xz
/llvm-3.9.0.src.tar.xz
/llvm-3.9.1.src.tar.xz
/llvm-4.0.0.src.tar.xz
/llvm-4.0.1.src.tar.xz
/llvm-5.0.0.src.tar.xz
/llvm-5.0.1.src.tar.xz
/llvm-6.0.0rc1.src.tar.xz
/llvm-6.0.0rc2.src.tar.xz
/llvm-6.0.0.src.tar.xz
/llvm-6.0.1rc1.src.tar.xz
/llvm-6.0.1rc2.src.tar.xz
/llvm-6.0.1.src.tar.xz
/llvm-7.0.0rc1.src.tar.xz
/llvm-7.0.0rc2.src.tar.xz
/llvm-7.0.0rc3.src.tar.xz
/llvm-7.0.0.src.tar.xz
/llvm-7.0.1.src.tar.xz
/llvm-8.0.0rc1.src.tar.xz
/llvm-8.0.0rc2.src.tar.xz
/llvm-8.0.0rc3.src.tar.xz
/llvm-8.0.0rc4.src.tar.xz
/llvm-8.0.0.src.tar.xz
/llvm-9.0.0rc2.src.tar.xz
/llvm-9.0.0rc3.src.tar.xz
/llvm-9.0.0.src.tar.xz
/llvm-9.0.1.src.tar.xz
/llvm-10.0.0rc1.src.tar.xz
/llvm-10.0.0rc1.src.tar.xz.sig
/llvm-10.0.0rc2.src.tar.xz
/llvm-10.0.0rc2.src.tar.xz.sig
/llvm-10.0.0rc3.src.tar.xz
/llvm-10.0.0rc3.src.tar.xz.sig
/llvm-10.0.0rc4.src.tar.xz
/llvm-10.0.0rc4.src.tar.xz.sig
/llvm-10.0.0rc5.src.tar.xz
/llvm-10.0.0rc5.src.tar.xz.sig
/llvm-10.0.0rc6.src.tar.xz
/llvm-10.0.0rc6.src.tar.xz.sig
/llvm-10.0.0.src.tar.xz
/llvm-10.0.0.src.tar.xz.sig
/llvm-11.0.0rc1.src.tar.xz
/llvm-11.0.0rc1.src.tar.xz.sig
/llvm-11.0.0rc2.src.tar.xz
/llvm-11.0.0rc2.src.tar.xz.sig
/llvm-11.0.0rc3.src.tar.xz
/llvm-11.0.0rc3.src.tar.xz.sig
/llvm-11.0.0rc5.src.tar.xz
/llvm-11.0.0rc5.src.tar.xz.sig
/llvm-11.0.0rc6.src.tar.xz
/llvm-11.0.0rc6.src.tar.xz.sig
/llvm-11.0.0.src.tar.xz
/llvm-11.0.0.src.tar.xz.sig
/llvm-11.0.1rc1.src.tar.xz
/llvm-11.0.1rc1.src.tar.xz.sig
/llvm-11.0.1rc2.src.tar.xz.sig
/llvm-11.0.1rc2.src.tar.xz
/llvm-11.0.1.src.tar.xz
/llvm-11.0.1.src.tar.xz.sig
/llvm-11.1.0rc1.src.tar.xz.sig
/llvm-11.1.0rc1.src.tar.xz
/llvm-11.1.0rc2.src.tar.xz
/llvm-11.1.0rc2.src.tar.xz.sig
/llvm-12.0.0rc1.src.tar.xz
/llvm-12.0.0rc1.src.tar.xz.sig
/llvm-12.0.0rc2.src.tar.xz
/llvm-12.0.0rc2.src.tar.xz.sig
/llvm-12.0.0rc3.src.tar.xz
/llvm-12.0.0rc3.src.tar.xz.sig
/llvm-12.0.0rc4.src.tar.xz
/llvm-12.0.0rc4.src.tar.xz.sig
/llvm-12.0.0rc5.src.tar.xz
/llvm-12.0.0rc5.src.tar.xz.sig
/llvm-12.0.0.src.tar.xz
/llvm-12.0.0.src.tar.xz.sig
/llvm-12.0.1rc1.src.tar.xz
/llvm-12.0.1rc1.src.tar.xz.sig
/llvm-12.0.1rc3.src.tar.xz
/llvm-12.0.1rc3.src.tar.xz.sig
/llvm-12.0.1.src.tar.xz
/llvm-12.0.1.src.tar.xz.sig
/llvm-13.0.0rc1.src.tar.xz
/llvm-13.0.0rc1.src.tar.xz.sig
/llvm-13.0.0rc3.src.tar.xz
/llvm-13.0.0rc3.src.tar.xz.sig
/llvm-13.0.0rc4.src.tar.xz
/llvm-13.0.0rc4.src.tar.xz.sig
/llvm-13.0.0.src.tar.xz
/llvm-13.0.0.src.tar.xz.sig
/llvm-13.0.1rc1.src.tar.xz
/llvm-13.0.1rc1.src.tar.xz.sig
/llvm-13.0.1rc2.src.tar.xz
/llvm-13.0.1rc2.src.tar.xz.sig
/llvm-13.0.1rc3.src.tar.xz
/llvm-13.0.1rc3.src.tar.xz.sig
/llvm-13.0.1.src.tar.xz
/llvm-13.0.1.src.tar.xz.sig
/llvm-14.0.0.src.tar.xz
/llvm-14.0.0.src.tar.xz.sig
/llvm-14.0.3.src.tar.xz
/llvm-14.0.3.src.tar.xz.sig
/llvm-14.0.5.src.tar.xz
/llvm-14.0.5.src.tar.xz.sig
/*.src.rpm
/*.src.tar.xz
/*.src.tar.xz.sig
/cmake/
/llvm-*.src/
/results_llvm/
/third-party/

View File

@ -1,35 +0,0 @@
From 3df079ae29426b4bee3ca11681a41958d72b983a Mon Sep 17 00:00:00 2001
From: Nikita Popov <npopov@redhat.com>
Date: Mon, 31 Jan 2022 10:33:27 +0100
Subject: [PATCH] Disable CrashRecoveryTest.DumpStackCleanup test on aarch64
Produces a non-reproducible failure on aarch64:
https://bugzilla.redhat.com/show_bug.cgi?id=2048440
---
llvm/unittests/Support/CrashRecoveryTest.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/llvm/unittests/Support/CrashRecoveryTest.cpp b/llvm/unittests/Support/CrashRecoveryTest.cpp
index e95513eb2841..afb1d3a1f6a2 100644
--- a/llvm/unittests/Support/CrashRecoveryTest.cpp
+++ b/llvm/unittests/Support/CrashRecoveryTest.cpp
@@ -76,6 +76,7 @@ TEST(CrashRecoveryTest, Cleanup) {
llvm::CrashRecoveryContext::Disable();
}
+#ifndef __aarch64__
TEST(CrashRecoveryTest, DumpStackCleanup) {
SmallString<128> Filename;
std::error_code EC = sys::fs::createTemporaryFile("crash", "test", Filename);
@@ -101,6 +102,7 @@ TEST(CrashRecoveryTest, DumpStackCleanup) {
EXPECT_EQ(GlobalInt, 1);
llvm::CrashRecoveryContext::Disable();
}
+#endif
TEST(CrashRecoveryTest, LimitedStackTrace) {
std::string Res;
--
2.34.1

View File

@ -1,33 +0,0 @@
From 9320ffeda3915c8f7be744c983a3470a89107bd7 Mon Sep 17 00:00:00 2001
From: Tom Stellard <tstellar@redhat.com>
Date: Tue, 14 Sep 2021 20:21:20 -0700
Subject: [PATCH] XFAIL missing-abstract-variable.ll test on ppc64le
It's seems the strategy with this test is to XFAIL it on all
architectures that it fails on. I wonder if we should be passing
it a specific triple? Also, from what I can tell, this tests only
runs when llvm is configured with LLVM_DEFAULT_TARGET_TRIPLE set
to a non-empty value, which is why it may not fail in every build
configuration.
Differential Revision: https://reviews.llvm.org/D109806
---
llvm/test/DebugInfo/Generic/missing-abstract-variable.ll | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll b/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll
index bd0de60268b6..cc5d56b0c512 100644
--- a/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll
+++ b/llvm/test/DebugInfo/Generic/missing-abstract-variable.ll
@@ -4,7 +4,7 @@
; powerpc64 (and on x86_64 at at least -O2). Presumably this is a SelectionDAG
; issue.
; FIXME: arm64 is an alias for aarch64 on macs, apparently?
-; XFAIL: powerpc64, aarch64, arm64, hexagon, riscv
+; XFAIL: powerpc64, aarch64, arm64, hexagon, riscv, ppc64le
; Build from the following source with clang -O2.
--
2.31.1

View File

@ -1,75 +0,0 @@
From 3dc5722d5c7673a879f2b4680369d3ac8b6b64b6 Mon Sep 17 00:00:00 2001
From: Tom Stellard <tstellar@redhat.com>
Date: Wed, 4 Aug 2021 14:05:38 -0700
Subject: [PATCH] cmake: Allow shared libraries to customize the soname using
LLVM_ABI_REVISION
The LLVM_ABI_REVISION variable is intended to be used for release
candidates which introduce an ABI change to a shared library. This
variable can be specified per library, so there is not one global value
for all of LLVM.
For example, if we LLVM X.0.0-rc2 introduces an ABI change for a library
compared with LLVM X.0.0-rc1, then the LLVM_ABI_REVISION number for
library will be incremented by 1.
In the main branch, LLVM_ABI_REVISION should always be 0, it is only
meant to be used in the release branch.
Differential Revision: https://reviews.llvm.org/D105594
---
llvm/cmake/modules/AddLLVM.cmake | 7 +++++--
llvm/tools/llvm-shlib/CMakeLists.txt | 9 +++++++++
3 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake
index 3e009f5061d3..a09405a1be3e 100644
--- a/llvm/cmake/modules/AddLLVM.cmake
+++ b/llvm/cmake/modules/AddLLVM.cmake
@@ -586,11 +586,14 @@ function(llvm_add_library name)
# Set SOVERSION on shared libraries that lack explicit SONAME
# specifier, on *nix systems that are not Darwin.
if(UNIX AND NOT APPLE AND NOT ARG_SONAME)
+ if (NOT LLVM_ABI_REVISION)
+ set(LLVM_ABI_REVISION 0)
+ endif()
set_target_properties(${name}
PROPERTIES
# Since 4.0.0, the ABI version is indicated by the major version
- SOVERSION ${LLVM_VERSION_MAJOR}${LLVM_VERSION_SUFFIX}
- VERSION ${LLVM_VERSION_MAJOR}${LLVM_VERSION_SUFFIX})
+ SOVERSION ${LLVM_VERSION_MAJOR}.${LLVM_ABI_REVISION}
+ VERSION ${LLVM_VERSION_MAJOR}.${LLVM_ABI_REVISION})
endif()
endif()
diff --git a/llvm/tools/llvm-shlib/CMakeLists.txt b/llvm/tools/llvm-shlib/CMakeLists.txt
index 76b9a25cbbcd..b876e7fed6b5 100644
--- a/llvm/tools/llvm-shlib/CMakeLists.txt
+++ b/llvm/tools/llvm-shlib/CMakeLists.txt
@@ -2,6 +2,11 @@
# library is enabled by setting LLVM_BUILD_LLVM_DYLIB=yes on the CMake
# commandline. By default the shared library only exports the LLVM C API.
+# In the main branch, LLVM_ABI_REVISION should always be 0. In the release
+# branches, this should be incremented before each release candidate every
+# time the ABI of libLLVM.so changes.
+set(LLVM_ABI_REVISION 0 CACHE STRING "ABI Revision number for SONAMEs (default: 0)")
+
set(SOURCES
libllvm.cpp
)
@@ -67,6 +72,10 @@ if(LLVM_BUILD_LLVM_DYLIB)
set_property(TARGET LLVM APPEND_STRING PROPERTY
LINK_FLAGS
" -compatibility_version 1 -current_version ${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}")
+ else()
+ set_target_properties(LLVM
+ PROPERTIES
+ SOVERSION ${LLVM_ABI_REVISION})
endif()
if(TARGET libLLVMExports)
--
2.27.0

View File

@ -0,0 +1,26 @@
diff -Naur a/llvm/docs/conf.py b/llvm/docs/conf.py
--- a/llvm/docs/conf.py 2020-09-15 09:12:24.318287611 +0000
+++ b/llvm/docs/conf.py 2020-09-15 15:01:00.025893199 +0000
@@ -36,21 +36,7 @@
".rst": "restructuredtext",
}
-try:
- import recommonmark
-except ImportError:
- # manpages do not use any .md sources
- if not tags.has("builder-man"):
- raise
-else:
- import sphinx
-
- if sphinx.version_info >= (3, 0):
- # This requires 0.5 or later.
- extensions.append("recommonmark")
- else:
- source_parsers = {".md": "recommonmark.parser.CommonMarkParser"}
- source_suffix[".md"] = "markdown"
+import sphinx
# The encoding of source files.
# source_encoding = 'utf-8-sig'

46
D156379.diff Normal file
View File

@ -0,0 +1,46 @@
diff --git a/llvm/lib/Target/SystemZ/SystemZTargetTransformInfo.cpp b/llvm/lib/Target/SystemZ/SystemZTargetTransformInfo.cpp
--- a/llvm/lib/Target/SystemZ/SystemZTargetTransformInfo.cpp
+++ b/llvm/lib/Target/SystemZ/SystemZTargetTransformInfo.cpp
@@ -1152,6 +1152,11 @@
}
}
+ // Type legalization (via getNumberOfParts) can't handle structs
+ if (TLI->getValueType(DL, Src, true) == MVT::Other)
+ return BaseT::getMemoryOpCost(Opcode, Src, Alignment, AddressSpace,
+ CostKind);
+
unsigned NumOps =
(Src->isVectorTy() ? getNumVectorRegs(Src) : getNumberOfParts(Src));
diff --git a/llvm/test/Analysis/CostModel/SystemZ/struct-cost-crash.ll b/llvm/test/Analysis/CostModel/SystemZ/struct-cost-crash.ll
new file mode 100644
--- /dev/null
+++ b/llvm/test/Analysis/CostModel/SystemZ/struct-cost-crash.ll
@@ -0,0 +1,25 @@
+; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py UTC_ARGS: --version 2
+; RUN: opt -passes="print<cost-model>" 2>&1 -disable-output < %s | FileCheck %s
+;
+; Check that SystemZTTIImpl::getMemoryOpCost doesn't try to legalize structs,
+; which was failing llvm_unreachable in MVT::getVT.
+
+target datalayout = "E-m:e-i1:8:16-i8:8:16-i64:64-f128:64-v128:64-a:8:16-n32:64"
+target triple = "s390x-unknown-linux-gnu"
+
+declare { i64, i32 } @bar()
+
+define i8 @foo() {
+; CHECK-LABEL: 'foo'
+; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: br label %1
+; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: %2 = call { i64, i32 } @bar()
+; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: store { i64, i32 } %2, ptr inttoptr (i64 16 to ptr), align 16
+; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: br label %1
+;
+ br label %1
+
+1: ; preds = %1, %0
+ %2 = call { i64, i32 } @bar()
+ store { i64, i32 } %2, ptr inttoptr (i64 16 to ptr), align 16
+ br label %1
+}

View File

@ -1,17 +0,0 @@
config.llvm_tools_dir = '/usr/bin'
config.llvm_shlib_dir = '%(llvm_shlib_dir)s' % lit_config.params
if hasattr(config, 'host_triple'):
# This means we are running lit regression tests
# Regression tests write output to this directory, so we need to be able to specify
# a temp directory when invoking lit. e.g. lit -Dllvm_obj_root=/tmp/lit
config.llvm_obj_root = "%(llvm_obj_root)s" % lit_config.params
lit_config.load_config(config, '%(llvm_test_root)s/lit.cfg.py' % lit_config.params)
else:
# This means we are running lit unit tests
# For unit tests, llvm_obj_root is used to find the unit test binaries.
config.llvm_obj_root = '%(llvm_unittest_bindir)s' % lit_config.params
lit_config.load_config(config, '%(llvm_test_root)s/Unit/lit.cfg.py' % lit_config.params)

View File

@ -1,9 +0,0 @@
#include <bits/wordsize.h>
#if __WORDSIZE == 32
#include "config-32.h"
#elif __WORDSIZE == 64
#include "config-64.h"
#else
#error "Unknown word size"
#endif

View File

@ -1,9 +0,0 @@
#include <bits/wordsize.h>
#if __WORDSIZE == 32
#include "llvm-config-32.h"
#elif __WORDSIZE == 64
#include "llvm-config-64.h"
#else
#error "Unknown word size"
#endif

394
llvm.spec
View File

@ -1,8 +1,17 @@
%bcond_with snapshot_build
%if %{with snapshot_build}
# Unlock LLVM Snapshot LUA functions
%{llvm_sb}
%endif
# We are building with clang for faster/lower memory LTO builds.
# See https://docs.fedoraproject.org/en-US/packaging-guidelines/#_compiler_macros
%ifnarch riscv64
%global toolchain clang
%endif
# Opt out of https://fedoraproject.org/wiki/Changes/fno-omit-frame-pointer
# https://bugzilla.redhat.com/show_bug.cgi?id=2158587
%undefine _include_frame_pointers
# Components enabled if supported by target architecture:
%define gold_arches %{ix86} x86_64 %{arm} aarch64 %{power64} s390x
@ -19,14 +28,37 @@
%bcond_with check
%endif
#global rc_ver 4
%global maj_ver 14
%global min_ver 0
%global patch_ver 5
%if !%{maj_ver} && 0%{?rc_ver}
%global abi_revision 2
%ifarch %ix86
# Disable LTO on x86 in order to reduce memory consumption
%bcond_with lto_build
%elif %{with snapshot_build}
# Disable LTO to speed up builds
%bcond_with lto_build
%else
%bcond_without lto_build
%endif
%global maj_ver 17
%global min_ver 0
%global patch_ver 4
#global rc_ver 4
%if %{with snapshot_build}
%undefine rc_ver
%global maj_ver %{llvm_snapshot_version_major}
%global min_ver %{llvm_snapshot_version_minor}
%global patch_ver %{llvm_snapshot_version_patch}
%endif
%global llvm_srcdir llvm-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:rc%{rc_ver}}.src
%global cmake_srcdir cmake-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:rc%{rc_ver}}.src
%global third_party_srcdir third-party-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:rc%{rc_ver}}.src
%ifnarch riscv64
%global _lto_cflags -flto=thin
%else
# riscv64: gold is not supported on riscv64
%global _lto_cflags %{nil}
%endif
%if %{with compat_build}
%global pkg_name llvm%{maj_ver}
@ -36,15 +68,15 @@
%global install_includedir %{install_prefix}/include
%global install_libdir %{install_prefix}/lib
%global pkg_bindir %{install_bindir}
%global pkg_includedir %{_includedir}/%{name}
%global pkg_libdir %{install_libdir}
%global pkg_datadir %{install_prefix}/share
%else
%global pkg_name llvm
%global install_prefix /usr
%global install_bindir %{_bindir}
%global install_libdir %{_libdir}
%global pkg_bindir %{_bindir}
%global pkg_libdir %{install_libdir}
%global install_includedir %{_includedir}
%global pkg_datadir %{_datadir}
%global exec_suffix %{nil}
%endif
@ -67,7 +99,7 @@
# we need to hard-code the correct triple here.
%global llvm_triple armv7l-redhat-linux-gnueabihf
%else
%global llvm_triple %{_host}
%global llvm_triple %{_target_platform}
%endif
# https://fedoraproject.org/wiki/Changes/PythonSafePath#Opting_out
@ -76,26 +108,29 @@
%undefine _py3_shebang_P
Name: %{pkg_name}
Version: %{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:~rc%{rc_ver}}
Release: 3.3.riscv64%{?dist}
Version: %{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:~rc%{rc_ver}}%{?llvm_snapshot_version_suffix:~%{llvm_snapshot_version_suffix}}
Release: 1.0.riscv64%{?dist}
Summary: The Low Level Virtual Machine
License: NCSA
License: Apache-2.0 WITH LLVM-exception OR NCSA
URL: http://llvm.org
%if %{with snapshot_build}
Source0: %{llvm_snapshot_source_prefix}llvm-%{llvm_snapshot_yyyymmdd}.src.tar.xz
Source2: %{llvm_snapshot_source_prefix}cmake-%{llvm_snapshot_yyyymmdd}.src.tar.xz
Source4: %{llvm_snapshot_source_prefix}third-party-%{llvm_snapshot_yyyymmdd}.src.tar.xz
%{llvm_snapshot_extra_source_tags}
%else
Source0: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{llvm_srcdir}.tar.xz
Source1: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{llvm_srcdir}.tar.xz.sig
Source2: tstellar-gpg-key.asc
%if %{without compat_build}
Source3: run-lit-tests
Source4: lit.fedora.cfg.py
Source2: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{cmake_srcdir}.tar.xz
Source3: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{cmake_srcdir}.tar.xz.sig
Source4: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{third_party_srcdir}.tar.xz
Source5: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{maj_ver}.%{min_ver}.%{patch_ver}%{?rc_ver:-rc%{rc_ver}}/%{third_party_srcdir}.tar.xz.sig
Source6: release-keys.asc
%endif
%if 0%{?abi_revision}
Patch0: 0001-cmake-Allow-shared-libraries-to-customize-the-soname.patch
%endif
Patch1: 0001-XFAIL-missing-abstract-variable.ll-test-on-ppc64le.patch
Patch2: 0001-Disable-CrashRecoveryTest.DumpStackCleanup-test-on-a.patch
# RHEL-specific patch to avoid unwanted recommonmark dep
Patch101: 0101-Deactivate-markdown-doc.patch
BuildRequires: gcc
BuildRequires: gcc-c++
@ -107,7 +142,9 @@ BuildRequires: libffi-devel
BuildRequires: ncurses-devel
BuildRequires: python3-psutil
BuildRequires: python3-sphinx
%if %{undefined rhel}
BuildRequires: python3-recommonmark
%endif
BuildRequires: multilib-rpm-config
%if %{with gold}
BuildRequires: binutils-devel
@ -144,14 +181,15 @@ Requires: %{name}-libs%{?_isa} = %{version}-%{release}
# app that requires the libLLVMLineEditor, so we need to make sure
# libedit-devel is available.
Requires: libedit-devel
# The installed cmake files reference binaries from llvm-test and llvm-static.
# We tried in the past to split the cmake exports for these binaries out into
# separate files, so that llvm-devel would not need to Require these packages,
# The installed cmake files reference binaries from llvm-test, llvm-static, and
# llvm-gtest. We tried in the past to split the cmake exports for these binaries
# out into separate files, so that llvm-devel would not need to Require these packages,
# but this caused bugs (rhbz#1773678) and forced us to carry two non-upstream
# patches.
Requires: %{name}-static%{?_isa} = %{version}-%{release}
%if %{without compat_build}
Requires: %{name}-test%{?_isa} = %{version}-%{release}
Requires: %{name}-googletest%{?_isa} = %{version}-%{release}
%endif
@ -187,6 +225,13 @@ Provides: llvm-static(major) = %{maj_ver}
%description static
Static libraries for the LLVM compiler infrastructure.
%package cmake-utils
Summary: CMake utilities shared across LLVM subprojects
%description cmake-utils
CMake utilities shared across LLVM subprojects.
This is for internal use by LLVM packages only.
%if %{without compat_build}
%package test
@ -208,8 +253,22 @@ LLVM's modified googletest sources.
%endif
%prep
%{gpgverify} --keyring='%{SOURCE2}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
%autosetup -n %{llvm_srcdir} -p2
%if %{without snapshot_build}
%{gpgverify} --keyring='%{SOURCE6}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
%{gpgverify} --keyring='%{SOURCE6}' --signature='%{SOURCE3}' --data='%{SOURCE2}'
%{gpgverify} --keyring='%{SOURCE6}' --signature='%{SOURCE5}' --data='%{SOURCE4}'
%endif
%setup -T -q -b 2 -n %{cmake_srcdir}
# TODO: It would be more elegant to set -DLLVM_COMMON_CMAKE_UTILS=%{_builddir}/%{cmake_srcdir},
# but this is not a CACHED variable, so we can't actually set it externally :(
cd ..
mv %{cmake_srcdir} cmake
%setup -T -q -b 4 -n %{third_party_srcdir}
cd ..
mv %{third_party_srcdir} third-party
%setup -T -q -b 0 -n %{llvm_srcdir}
%autopatch -M%{?!rhel:100}%{?rhel:200} -p2
%py3_shebang_fix \
test/BugPoint/compile-custom.ll.py \
@ -218,11 +277,8 @@ LLVM's modified googletest sources.
%build
%ifarch s390 s390x riscv64
# Fails with "exceeded PCRE's backtracking limit"
%if %{without lto_build}
%global _lto_cflags %nil
%else
%global _lto_cflags -flto=thin
%endif
%ifarch s390 s390x %{arm} %ix86 riscv64
@ -230,7 +286,11 @@ LLVM's modified googletest sources.
%global optflags %(echo %{optflags} | sed 's/-g /-g1 /')
%endif
# Copy CFLAGS into ASMFLAGS, so -fcf-protection is used when compiling assembly files.
export ASMFLAGS="%{build_cflags}"
# force off shared libs as cmake macros turns it on.
# TODO: Disable LLVM_UNREACHABLE_OPTIMIZE.
%cmake -G Ninja \
-DBUILD_SHARED_LIBS:BOOL=OFF \
-DLLVM_PARALLEL_LINK_JOBS=1 \
@ -266,6 +326,11 @@ LLVM's modified googletest sources.
\
-DLLVM_INCLUDE_TESTS:BOOL=ON \
-DLLVM_BUILD_TESTS:BOOL=ON \
%if %{with compat_build}
-DLLVM_INSTALL_GTEST:BOOL=OFF \
%else
-DLLVM_INSTALL_GTEST:BOOL=ON \
%endif
-DLLVM_LIT_ARGS=-v \
\
-DLLVM_INCLUDE_EXAMPLES:BOOL=ON \
@ -285,21 +350,26 @@ LLVM's modified googletest sources.
-DLLVM_ENABLE_SPHINX:BOOL=ON \
-DLLVM_ENABLE_DOXYGEN:BOOL=OFF \
\
%if %{without compat_build}
%if %{with snapshot_build}
-DLLVM_VERSION_SUFFIX="%{llvm_snapshot_version_suffix}" \
%else
-DLLVM_VERSION_SUFFIX='' \
%endif
-DLLVM_UNREACHABLE_OPTIMIZE:BOOL=ON \
-DLLVM_BUILD_LLVM_DYLIB:BOOL=ON \
-DLLVM_LINK_LLVM_DYLIB:BOOL=ON \
-DLLVM_BUILD_EXTERNAL_COMPILER_RT:BOOL=ON \
-DLLVM_INSTALL_TOOLCHAIN_ONLY:BOOL=OFF \
%{?abi_revision:-DLLVM_ABI_REVISION=%{abi_revision}} \
\
-DLLVM_DEFAULT_TARGET_TRIPLE=%{llvm_triple} \
-DSPHINX_WARNINGS_AS_ERRORS=OFF \
-DCMAKE_INSTALL_PREFIX=%{install_prefix} \
-DLLVM_INSTALL_SPHINX_HTML_DIR=%{_pkgdocdir}/html \
-DSPHINX_EXECUTABLE=%{_bindir}/sphinx-build-3 \
-DLLVM_INCLUDE_BENCHMARKS=OFF
-DLLVM_INCLUDE_BENCHMARKS=OFF \
%if %{with lto_build}
-DLLVM_UNITTEST_LINK_FLAGS="-Wl,-plugin-opt=O0" \
%endif
-DCMAKE_SHARED_LINKER_FLAGS="$LDFLAGS -Wl,-z,cet-report=error"
# Build libLLVM.so first. This ensures that when libLLVM.so is linking, there
# are no other compile jobs running. This will help reduce OOM errors on the
@ -331,24 +401,10 @@ rm -rf test/tools/UpdateTestChecks
%multilib_fix_c_header --file %{_includedir}/llvm/Config/llvm-config.h
# Install libraries needed for unittests
%if 0%{?__isa_bits} == 64
%global build_libdir %{_vpath_builddir}/lib64
%else
%global build_libdir %{_vpath_builddir}/lib
%endif
%global build_libdir %{_vpath_builddir}/%{_lib}
install %{build_libdir}/libLLVMTestingSupport.a %{buildroot}%{_libdir}
%global install_srcdir %{buildroot}%{_datadir}/llvm/src
# Install gtest sources so clang can use them for gtest
install -d %{install_srcdir}
install -d %{install_srcdir}/utils/
cp -R utils/unittest %{install_srcdir}/utils/
# Clang needs these for running lit tests.
cp utils/update_cc_test_checks.py %{install_srcdir}/utils/
cp -R utils/UpdateTestChecks %{install_srcdir}/utils/
install %{build_libdir}/libLLVMTestingAnnotations.a %{buildroot}%{_libdir}
%if %{with gold}
# Add symlink to lto plugin in the binutils plugin directory.
@ -361,7 +417,7 @@ ln -s -t %{buildroot}%{_libdir}/bfd-plugins/ ../LLVMgold.so
# Add version suffix to binaries
for f in %{buildroot}/%{install_bindir}/*; do
filename=`basename $f`
ln -s ../../../%{install_bindir}/$filename %{buildroot}/%{_bindir}/$filename%{exec_suffix}
ln -s ../../%{install_bindir}/$filename %{buildroot}/%{_bindir}/$filename%{exec_suffix}
done
# Move header files
@ -373,9 +429,9 @@ ln -s ../../../%{install_includedir}/llvm-c %{buildroot}/%{pkg_includedir}/llvm-
%multilib_fix_c_header --file %{install_includedir}/llvm/Config/llvm-config.h
# Create ld.so.conf.d entry
mkdir -p %{buildroot}%{_sysconfdir}/ld.so.conf.d
cat >> %{buildroot}%{_sysconfdir}/ld.so.conf.d/%{name}-%{_arch}.conf << EOF
%{pkg_libdir}
mkdir -p %{buildroot}/etc/ld.so.conf.d
cat >> %{buildroot}/etc/ld.so.conf.d/%{name}-%{_arch}.conf << EOF
%{install_libdir}
EOF
# Add version suffix to man pages and move them to mandir.
@ -397,29 +453,27 @@ rm -Rf %{build_install_prefix}/share/opt-viewer
%if %{without compat_build}
mv %{buildroot}/%{pkg_bindir}/llvm-config %{buildroot}/%{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
mv %{buildroot}/%{install_bindir}/llvm-config %{buildroot}/%{install_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
# We still maintain a versionned symlink for consistency across llvm versions.
# This is specific to the non-compat build and matches the exec prefix for
# compat builds. An isa-agnostic versionned symlink is also maintained in the (un)install
# steps.
(cd %{buildroot}/%{pkg_bindir} ; ln -s llvm-config%{exec_suffix}-%{__isa_bits} llvm-config-%{maj_ver}-%{__isa_bits} )
(cd %{buildroot}/%{install_bindir} ; ln -s llvm-config%{exec_suffix}-%{__isa_bits} llvm-config-%{maj_ver}-%{__isa_bits} )
# ghost presence
touch %{buildroot}%{_bindir}/llvm-config-%{maj_ver}
%else
rm %{buildroot}%{_bindir}/llvm-config%{exec_suffix}
(cd %{buildroot}/%{pkg_bindir} ; ln -s llvm-config llvm-config%{exec_suffix}-%{__isa_bits} )
(cd %{buildroot}/%{install_bindir} ; ln -s llvm-config llvm-config%{exec_suffix}-%{__isa_bits} )
%endif
# ghost presence
touch %{buildroot}%{_bindir}/llvm-config%{exec_suffix}
%if %{without compat_build}
cp -Rv ../cmake/Modules/* %{buildroot}%{_libdir}/cmake/llvm
%endif
mkdir -p %{buildroot}%{pkg_datadir}/llvm/cmake
cp -Rv ../cmake/* %{buildroot}%{pkg_datadir}/llvm/cmake
%check
# Disable check section on arm due to some kind of memory related failure.
@ -436,7 +490,7 @@ rm test/tools/dsymutil/X86/swift-interface.test
%if %{with check}
# FIXME: use %%cmake_build instead of %%__ninja
LD_LIBRARY_PATH=%{buildroot}/%{pkg_libdir} %{__ninja} check-all -C %{_vpath_builddir}
LD_LIBRARY_PATH=%{buildroot}/%{install_libdir} %{__ninja} check-all -C %{_vpath_builddir}
%endif
%endif
@ -444,16 +498,16 @@ LD_LIBRARY_PATH=%{buildroot}/%{pkg_libdir} %{__ninja} check-all -C %{_vpath_bui
%ldconfig_scriptlets libs
%post devel
%{_sbindir}/update-alternatives --install %{_bindir}/llvm-config%{exec_suffix} llvm-config%{exec_suffix} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits} %{__isa_bits}
%{_sbindir}/update-alternatives --install %{_bindir}/llvm-config%{exec_suffix} llvm-config%{exec_suffix} %{install_bindir}/llvm-config%{exec_suffix}-%{__isa_bits} %{__isa_bits}
%if %{without compat_build}
%{_sbindir}/update-alternatives --install %{_bindir}/llvm-config-%{maj_ver} llvm-config-%{maj_ver} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits} %{__isa_bits}
%{_sbindir}/update-alternatives --install %{_bindir}/llvm-config-%{maj_ver} llvm-config-%{maj_ver} %{install_bindir}/llvm-config%{exec_suffix}-%{__isa_bits} %{__isa_bits}
%endif
%postun devel
if [ $1 -eq 0 ]; then
%{_sbindir}/update-alternatives --remove llvm-config%{exec_suffix} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%{_sbindir}/update-alternatives --remove llvm-config%{exec_suffix} %{install_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%if %{without compat_build}
%{_sbindir}/update-alternatives --remove llvm-config-%{maj_ver} %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%{_sbindir}/update-alternatives --remove llvm-config-%{maj_ver} %{install_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%endif
fi
@ -464,11 +518,11 @@ fi
%{_bindir}/*
%exclude %{_bindir}/llvm-config%{exec_suffix}
%exclude %{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%exclude %{install_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%if %{without compat_build}
%exclude %{_bindir}/llvm-config-%{maj_ver}
%exclude %{pkg_bindir}/llvm-config-%{maj_ver}-%{__isa_bits}
%exclude %{install_bindir}/llvm-config-%{maj_ver}-%{__isa_bits}
%exclude %{_bindir}/not
%exclude %{_bindir}/count
%exclude %{_bindir}/yaml-bench
@ -477,53 +531,48 @@ fi
%exclude %{_bindir}/llvm-opt-fuzzer
%{_datadir}/opt-viewer
%else
%{pkg_bindir}
%{install_bindir}
%endif
%files libs
%license LICENSE.TXT
%{pkg_libdir}/libLLVM-%{maj_ver}.so
%{install_libdir}/libLLVM-%{maj_ver}%{?llvm_snapshot_version_suffix:%{llvm_snapshot_version_suffix}}.so
%if %{without compat_build}
%if %{with gold}
%{_libdir}/LLVMgold.so
%{_libdir}/bfd-plugins/LLVMgold.so
%endif
%{_libdir}/libLLVM-%{maj_ver}.%{min_ver}*.so
%{_libdir}/libLLVM-%{maj_ver}.so%{?abi_revision:.%{abi_revision}}
%{_libdir}/libLTO.so*
%else
%config(noreplace) %{_sysconfdir}/ld.so.conf.d/%{name}-%{_arch}.conf
%config(noreplace) /etc/ld.so.conf.d/%{name}-%{_arch}.conf
%if %{with gold}
%{_libdir}/%{name}/lib/LLVMgold.so
%endif
%{pkg_libdir}/libLLVM-%{maj_ver}.%{min_ver}*.so
%{pkg_libdir}/libLTO.so*
%exclude %{pkg_libdir}/libLTO.so
%{install_libdir}/libLLVM-%{maj_ver}.%{min_ver}*.so
%{install_libdir}/libLTO.so*
%exclude %{install_libdir}/libLTO.so
%endif
%{pkg_libdir}/libRemarks.so*
%{install_libdir}/libRemarks.so*
%files devel
%license LICENSE.TXT
%ghost %{_bindir}/llvm-config%{exec_suffix}
%{pkg_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%{install_bindir}/llvm-config%{exec_suffix}-%{__isa_bits}
%{_mandir}/man1/llvm-config*
%if %{without compat_build}
%{_includedir}/llvm
%{_includedir}/llvm-c
%{_libdir}/libLLVM.so
%{_libdir}/cmake/llvm
%{pkg_bindir}/llvm-config-%{maj_ver}-%{__isa_bits}
%ghost %{_bindir}/llvm-config-%{maj_ver}
%else
%{install_includedir}/llvm
%{install_includedir}/llvm-c
%{install_libdir}/libLLVM.so
%{install_libdir}/cmake/llvm
%if %{without compat_build}
%{install_bindir}/llvm-config-%{maj_ver}-%{__isa_bits}
%ghost %{_bindir}/llvm-config-%{maj_ver}
%else
%{pkg_includedir}/llvm
%{pkg_includedir}/llvm-c
%{pkg_libdir}/libLTO.so
%{pkg_libdir}/libLLVM.so
%{pkg_libdir}/cmake/llvm
%{install_libdir}/libLTO.so
%endif
%files doc
@ -532,13 +581,18 @@ fi
%files static
%license LICENSE.TXT
%{install_libdir}/*.a
%if %{without compat_build}
%{_libdir}/*.a
%exclude %{_libdir}/libLLVMTestingSupport.a
%else
%{_libdir}/%{name}/lib/*.a
%exclude %{install_libdir}/libLLVMTestingSupport.a
%exclude %{install_libdir}/libLLVMTestingAnnotations.a
%exclude %{install_libdir}/libllvm_gtest.a
%exclude %{install_libdir}/libllvm_gtest_main.a
%endif
%files cmake-utils
%license LICENSE.TXT
%{pkg_datadir}/llvm/cmake
%if %{without compat_build}
%files test
@ -552,24 +606,148 @@ fi
%files googletest
%license LICENSE.TXT
%{_datadir}/llvm/src/utils
%{_libdir}/libLLVMTestingSupport.a
%{install_libdir}/libLLVMTestingSupport.a
%{install_libdir}/libLLVMTestingAnnotations.a
%{install_libdir}/libllvm_gtest.a
%{install_libdir}/libllvm_gtest_main.a
%{install_includedir}/llvm-gtest
%{install_includedir}/llvm-gmock
%endif
%changelog
* Sun Aug 21 2022 David Abdurachmanov <davidlt@rivosinc.com> - 14.0.5-3.3.riscv64
- Disable tests on riscv64
%{?llvm_snapshot_changelog_entry}
* Fri Aug 19 2022 David Abdurachmanov <davidlt@rivosinc.com> - 14.0.5-3.2.riscv64
- Disable LTO on riscv64 (there is no thin LTO on GCC)
* Fri Aug 19 2022 David Abdurachmanov <davidlt@rivosinc.com> - 14.0.5-3.1.riscv64
- Build with GCC on riscv64
* Fri Aug 19 2022 David Abdurachmanov <davidlt@rivosinc.com> - 14.0.5-3.0.riscv64
* Thu Nov 02 2023 David Abdurachmanov <davidlt@rivosinc.com> - 17.0.4-1.0.riscv64
- Disable tests on riscv64 for now
- Lower memory consumption on riscv64
* Tue Oct 31 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.4-1
- Update to LLVM 17.0.4
* Tue Oct 17 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.3-1
- Update to LLVM 17.0.3
* Tue Oct 03 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.2-1
- Update to LLVM 17.0.2
* Fri Sep 22 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.1~rc4-1
- Update to LLVM 17.0.1
* Tue Sep 05 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc4-1
- Update to LLVM 17.0.0 RC4
* Thu Aug 24 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc3-1
- Update to LLVM 17.0.0 RC3
* Thu Aug 24 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc2-2
- Temporarily disable a failing test on ppc64le
* Thu Aug 17 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc2-1
- Update to LLVM 17.0.0 RC2
* Wed Aug 16 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-4
- Disable LTO on i686
* Mon Aug 14 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-3
- Re-add patch removed by mistake
* Tue Aug 01 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-2
- Enable LLVM_UNREACHABLE_OPTIMIZE temporarily
* Mon Jul 31 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 17.0.0~rc1-1
- Update to LLVM 17.0.0 RC1
* Mon Jul 31 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.6-6
- Fix rhbz #2224885
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 16.0.6-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Mon Jul 10 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.6-4
- Use LLVM_UNITTEST_LINK_FLAGS to reduce link times for unit tests
* Mon Jul 03 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.6-3
- Improve error messages for unsupported relocs on s390x (rhbz#2216906)
- Disable LLVM_UNREACHABLE_OPTIMIZE
* Wed Jun 14 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.6-1
- Update to LLVM 16.0.6
* Fri Jun 09 2023 Nikita Popov <npopov@redhat.com> - 16.0.5-2
- Split off llvm-cmake-utils package
* Mon Jun 05 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.5-1
- Update to LLVM 16.0.5
* Fri May 19 2023 Yaakov Selkowitz <yselkowi@redhat.com> - 16.0.4-2
- Avoid recommonmark dependency in RHEL builds
* Thu May 18 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.4-1
- Update to LLVM 16.0.4
* Tue May 09 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.3-1
- Update to LLVM 16.0.3
* Tue Apr 25 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.2-1
- Update to LLVM 16.0.2
* Tue Apr 11 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.1-1
- Update to LLVM 16.0.1
* Thu Mar 23 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.0-2
- Distribute libllvm_gtest.a and libllvm_gtest_main.a with llvm-googletest
- Stop distributing /usr/share/llvm/src/utils
* Mon Mar 20 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.0-1
- Update to LLVM 16.0.0
* Thu Mar 16 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.0~rc4-2
- Fix the ppc64le triple
* Tue Mar 14 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.0~rc4-1
- Update to LLVM 16.0.0 RC4
* Fri Mar 10 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.0~rc3-2
- Fix llvm-exegesis failures on s390x
* Wed Feb 22 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.0~rc3-1
- Update to LLVM 16.0.0 RC3
* Wed Feb 01 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 16.0.0~rc1-1
- Update to LLVM 16.0.0 RC1
* Thu Jan 19 2023 Tulio Magno Quites Machado Filho <tuliom@redhat.com> - 15.0.7-3
- Update license to SPDX identifiers.
- Include the Apache license adopted in 2019.
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 15.0.7-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Jan 12 2023 Nikita Popov <npopov@redhat.com> - 15.0.7-1
- Update to LLVM 15.0.7
* Mon Jan 09 2023 Tom Stellard <tstellar@redhat.com> - 15.0.6-3
- Omit frame pointers when building
* Mon Dec 19 2022 Nikita Popov <npopov@redhat.com> - 15.0.6-2
- Remove workaround for rbhz#2048440
* Mon Dec 05 2022 Nikita Popov <npopov@redhat.com> - 15.0.6-1
- Update to LLVM 15.0.6
* Fri Nov 11 2022 Nikita Popov <npopov@redhat.com> - 15.0.4-2
- Copy CFLAGS to ASMFLAGs to enable CET in asm files
* Wed Nov 02 2022 Nikita Popov <npopov@redhat.com> - 15.0.4-1
- Update to LLVM 15.0.4
* Tue Sep 27 2022 Nikita Popov <npopov@redhat.com> - 15.0.0-2
- Export GetHostTriple.cmake
* Tue Sep 06 2022 Nikita Popov <npopov@redhat.com> - 15.0.0-1
- Update to LLVM 15.0.0
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 14.0.5-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild

104
release-keys.asc Normal file
View File

@ -0,0 +1,104 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
mQGNBGLtemUBDADClvDIromq0Y4TX+wyRyYCq5WusPQheQuY8dVCXd9KhMpYAv8U
X15E5boH/quGpJ0ZlVkWcf+1WUHIrQWlbzQdIx514CDM7DBgO92CXsnn86kIMDW+
9S+Hkn8upbizT1fWritlHwzD9osz7ZQRq7ac03PPgw27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E0PBLVt09vlr4i8jAsQvDrzRajmVPd2B9RpfNU6HJe/y93SZd2
udr9vzgmfd2o5u12vbegKNiMRgp1VyHQDmYlce27jrH5aPuKmos78+o5/p5yPWCv
Rj8zxGKh7le7UPO+7UveKu+bgb3zwTj6bEuHX7fVI+WjGmEH3bbjDGamWxXrpfGc
7+Jr8TN4ZO2OwYBcFOS9U2ZQ6TxrPaCSIm6+j8f+a9HPOuuDc62mMuV/EWQZy0i7
DhDqU2PNpVjQDWQNpHA8oLDrjNFAoJS8gbHABVsFM1VnwBNT2MKcZQmm05dlQ+ll
S6meHNCvTniKIKC+Giz1Yd5JVGDACZWWPxEz6VhpQW/twkxRqwlUdpFt7UgDquTL
M1beQUCZRt81yJTNdrggbhQ2POxOdIO0CPiQv7U1IzndZp6baedeBw4a7FCbj6GY
cQeHxQCrWpQrwigiseG5uhhS9aiaVFEHja9baSLfXlZu/vsR4MdDG5/iEpier/Xw
h1qnpTSY+r31Uw3lTUlPHzlg47PMgPslaIhCzfVggxh9bTqxcDbuYJ7NuoMho3tN
yWfeofTJ7PhKzoXM2Y/rRFoM5gNh1RVA19ngLT5Jwiof8fPZvHJ/9ZkHn+O7eMNm
m5++gYza3pnn2/PoGpGGAKok+sfJiq5Tb7RUefyJTeZiyTZ/XJrA
=tMzl
-----END PGP PUBLIC KEY BLOCK-----

View File

@ -1,59 +0,0 @@
#!/bin/bash
usage() {
echo "usage: `basename $0` [OPTIONS]"
echo " --threads NUM The number of threads to use for running tests."
echo " --multilib-arch ARCH Use this option to test 32-bit libs/binaries on"
echo " 64-bit hosts."
}
threads_arg=''
while [ $# -gt 0 ]; do
case $1 in
--threads)
shift
threads_arg="--threads $1"
;;
--multilib-arch)
shift
ARCH=$1
;;
* )
echo "unknown option: $1"
echo ""
usage
exit 1
;;
esac
shift
done
set -xe
if [ -z "$ARCH" ]; then
ARCH=`rpm --eval '%_arch'`
fi
case $ARCH in
arm)
;&
i686)
LIB_DIR="/usr/lib/"
;;
*)
LIB_DIR="/usr/lib64/"
;;
esac
cd $(mktemp -d)
ln -s /usr/include include
ln -s /usr/share/llvm/src/docs docs
tar -xzf /usr/share/llvm/src/test.tar.gz
ln -s /usr/share/llvm/src/$ARCH.site.cfg.py test/lit.site.cfg.py
ln -s /usr/share/llvm/src/$ARCH.Unit.site.cfg.py test/Unit/lit.site.cfg.py
lit -v -s $threads_arg test \
-Dllvm_obj_root=`pwd` \
-Dllvm_test_root=`pwd`/test \
-Dllvm_unittest_bindir=$LIB_DIR/llvm \
-Dllvm_shlib_dir=$LIB_DIR

View File

@ -1,2 +1,6 @@
SHA512 (llvm-14.0.5.src.tar.xz) = 03b9ecedd14eb034d16fde945d395672990b2140bff713a65e701711ef5934b967850762fcb2d75db72abb56ad0354d4f5d768f1005add979a859c93565004d2
SHA512 (llvm-14.0.5.src.tar.xz.sig) = d994b6b92a6c3eba93f328f582287d834bdd068ff80030659f74c35f6da501e8121eb03a5a9431aa0a556145fc9087d2081352106d75305032b6020d2278683f
SHA512 (llvm-17.0.4.src.tar.xz) = 4736fd8d7ee9aacf1d959e78b98dc1b5e3235a233ce4094a8cb262b3f29d101332947e5abcd242ff680b5b91901637ab006ae720339be7dcf68c82b14ea2f266
SHA512 (llvm-17.0.4.src.tar.xz.sig) = 1391cb19f4da73a564feb88da4f464887f89e886986b070dae1a0b926c64ee60181e8ae4e31278e09e76ee2164383e630e44145d025824adde413444567544d2
SHA512 (cmake-17.0.4.src.tar.xz) = bddfa97e6d1866a571d036490321099593063be33c38be1c6d117ea26d311876526d13760dc63155d3a7ea460f9c3de6da9911bdebeb286964ccdab377085a28
SHA512 (cmake-17.0.4.src.tar.xz.sig) = 6a0d25cdbf24ff0bdeb3c21dea413cfb72420954bafd2080dc865a015d7b688019b654d0865440b1eb464e251b25a13adec8d313dc0fec33f4f6b6bf7aec8942
SHA512 (third-party-17.0.4.src.tar.xz) = 779bddf99829a9d0abdfe277855711a573fc95f135fa1e3eb2d1a51f9da680bc6973db2f29a238888c914c7e6381aabe5f91db01c06686aff37e5d28d8906f90
SHA512 (third-party-17.0.4.src.tar.xz.sig) = 46e35713b0ff53f782b4e9d90ee8fc57271da29bb41af1f28f65a346354131f94088a28bbfc081e8fe4c13e3aa59582267384d48d96e029690e3e067f8219f08

6
tests/README.md Normal file
View File

@ -0,0 +1,6 @@
# Gating testplans for LLVM
The tests for LLVM are in a separate repo: https://src.fedoraproject.org/tests/llvm
This directory should contain only fmf plans (such as build-gating.fmf) which import
the tests from the tests repo. This can be done using the "url" parameter of the
plan's "discover" step. Reference: https://tmt.readthedocs.io/en/stable/spec/plans.html#fmf

View File

@ -1,2 +0,0 @@
summary: Make sure the the LLVM plugin for binutils' ar works
test: "$WITH_SCL ./test.sh"

View File

@ -1,7 +0,0 @@
#!/bin/sh -eux
set pipefail
echo "void lto_function(){}" | clang -flto -O2 -c -x c -o foo.o -
ar crs foo.a foo.o
readelf -c foo.a | grep lto_function

View File

@ -1,3 +0,0 @@
summary: Make sure rebuilding LLVM still works with the new LLVM
test: "$WITH_SCL ./test.sh"
enabled: false

View File

@ -1,14 +0,0 @@
#!/bin/sh -eux
dnf download --disablerepo=* --enablerepo=test-llvm --source llvm
# The src.rpm is available in the directory the test run from.
set +e
mock --resultdir=. --old-chroot --with compat_build --rebuild *.src.rpm
if [ $? -ne 0 ]; then
cat root.log
cat build.log
exit 1
fi
exit 0

View File

@ -48,7 +48,10 @@ adjust:
or distro == rhel-8
discover:
- name: llvm-tests
how: fmf
url: https://src.fedoraproject.org/tests/llvm.git
ref: main
execute:
how: tmt
provision:

View File

@ -1,81 +0,0 @@
summary: Run the upstream LLVM integration test suite
description: |
Run the upstream LLVM integration test suite
test: "$WITH_SCL ./test.sh"
require:
- git
- make
# These require special repositories to be enabled on RHEL
- libstdc++-static
adjust:
# Common requirements when LLVM is not SCL-ized
- require+:
- cmake
- clang
- clang-analyzer
- clang-devel
- clang-tools-extra
- compiler-rt
- lld
- lldb
- libomp-devel
- llvm-devel
- python3-lit
when: "collection is not defined"
# Requirements for SCL-ized LLVM
- require+:
- llvm-toolset-13.0-cmake
- llvm-toolset-13.0-clang
- llvm-toolset-13.0-clang-analyzer
- llvm-toolset-13.0-clang-devel
- llvm-toolset-13.0-clang-tools-extra
- llvm-toolset-13.0-compiler-rt
- llvm-toolset-13.0-lld
- llvm-toolset-13.0-lldb
- llvm-toolset-13.0-libomp-devel
- llvm-toolset-13.0-llvm-devel
- llvm-toolset-13.0-python3-lit
when: "collection == llvm-toolset-13.0"
- require+:
- llvm-toolset-14.0-cmake
- llvm-toolset-14.0-clang
- llvm-toolset-14.0-clang-analyzer
- llvm-toolset-14.0-clang-devel
- llvm-toolset-14.0-clang-tools-extra
- llvm-toolset-14.0-compiler-rt
- llvm-toolset-14.0-lld
- llvm-toolset-14.0-lldb
- llvm-toolset-14.0-libomp-devel
- llvm-toolset-14.0-llvm-devel
- llvm-toolset-14.0-python3-lit
when: "collection == llvm-toolset-14.0"
# lld not supported in s390x or ppc64. If any lld package was added to
# requirements, remove it.
- require-:
- lld
- llvm-toolset-13.0-lld
- llvm-toolset-14.0-lld
when: arch == s390x or arch == ppc64
# libomp not supported in s390x. If any libomp-devel package was added to
# requirements, remove it.
- require-:
- libomp-devel
- llvm-toolset-13.0-libomp-devel
- llvm-toolset-14.0-libomp-devel
when: arch == s390x
# libcxx shall be required in Fedora, it's not shipped with RHEL.
- require+:
- libcxx-devel
when: "distro == fedora"
because: testing against libcxx package in Fedora
- environment+:
CMAKE_CXXLIB: "-DENABLE_LIBCXX=OFF"
when: >-
distro == centos
or distro == rhel
because: libcxx is not shipped with neither Centos nor RHEL

View File

@ -1,39 +0,0 @@
#!/bin/sh -eux
usage() {
echo "usage `basename $0` [OPTIONS]"
echo " --threads NUM The number of threads to use for running tests."
}
threads=0
thread_args=""
repo_url=https://github.com/opencollab/llvm-toolchain-integration-test-suite
while [ $# -gt 0 ]; do
case $1 in
--threads)
shift
threads="$1"
;;
* )
echo "unknown option: $1"
echo ""
usage
exit 1
;;
esac
shift
done
if [ "$threads" -ge 1 ]; then
thread_args="-j$threads"
fi
cd $(mktemp -d -p /var/tmp)
git clone $repo_url
cd llvm-toolchain-integration-test-suite
mkdir _build && cd _build
cmake .. ${CMAKE_CXXLIB:-}
# Do not run with make as it will return 2 in case of failures, which will be
# reported by tmt as error instead failure. Run with lit so it returns 1.
lit --show-unsupported --show-xfail -v tests

View File

@ -1,13 +0,0 @@
summary: Check that libLLVM.so has been properly stripped
test: "$WITH_SCL ./test.sh"
environment:
LIBLLVM_PATH: /usr/lib64/libLLVM.so
adjust:
- because: "With SCL-ized LLVM, library path is different"
environment+:
LIBLLVM_PATH: /opt/rh/llvm-toolset-13.0/root/usr/lib64/libLLVM.so
when: "collection == llvm-toolset-13.0"
- because: "With SCL-ized LLVM, library path is different"
environment+:
LIBLLVM_PATH: /opt/rh/llvm-toolset-14.0/root/usr/lib64/libLLVM.so
when: "collection == llvm-toolset-14.0"

View File

@ -1,10 +0,0 @@
#!/bin/sh -eux
# There is a bug in the build process when it runs out of disk space
# while stripping binaries, which causes the strip to fail, but does
# not fail the build. This results in a libLLVM.so that is over 2GB
# which breaks the nightly compose. So this test checks that libLLVM.so
# is less than 150MB to ensure it was successfully stripped.
# https://bugzilla.redhat.com/show_bug.cgi?id=1793250
test $(stat -L -c %s $LIBLLVM_PATH) -lt 157286400

View File

@ -1,2 +0,0 @@
summary: Make sure llvm-config symlink is properly set up
test: "$WITH_SCL ./test.sh"

View File

@ -1,3 +0,0 @@
#!/bin/sh -eux
llvm-config --version

View File

@ -1,30 +0,0 @@
summary: Test basic cargo usage
test: "$WITH_SCL ./test.sh"
require: []
adjust:
# Common requirements when LLVM is not SCL-ized
- require+:
# Required for rust and possibly other dependant packages
#
# NOTE #1: drop the requirement once the transitional period between releases is gone
# and llvm-compat is no longer a) needed, and b) part of the build.
#
# NOTE #2: keep it the first requirement. Depending on the order of requirements, placing it somewhere
# else in the list may lead to harness uninstalling and re-installing LLVM packages. That a) would be
# a waste of time, b) could potentially hide issues, leading to testing unexpected NVRs.
#
# - llvm-compat
- cargo
- rust
when: "collection is not defined"
# Requirements for SCL-ized LLVM
- require+:
- rust-toolset-1.58-cargo
- rust-toolset-1.58-rust
when: "collection == llvm-toolset-13.0"
- require+:
- rust-toolset-1.62-cargo
- rust-toolset-1.62-rust
when: "collection == llvm-toolset-14.0"

View File

@ -1,5 +0,0 @@
#!/bin/sh -eux
cargo new hello
cd hello
cargo run

View File

@ -1,2 +0,0 @@
summary: Make sure the versioned llvm-config symlink is properly set up
test: "$WITH_SCL ./test.sh"

View File

@ -1,5 +0,0 @@
#!/bin/sh -eux
major=$(llvm-config --version | cut -d '.' -f1)
llvm-config-$major --version

Binary file not shown.