# header-only library %global debug_package %{nil} %bcond_with check %global forgeurl https://gitlab.cern.ch/VecGeom/VecCore Version: 0.8.0 %global tag v%{version} %forgemeta Name: veccore Release: %autorelease Summary: C++ Library for Portable SIMD Vectorization License: LGPLv2 URL: %{forgeurl} Source0: %{forgesource} # https://fedoraproject.org/wiki/Changes/EncourageI686LeafRemoval ExcludeArch: %{ix86} BuildRequires: gcc-c++ BuildRequires: cmake BuildRequires: ninja-build BuildRequires: gtest-devel %description VecCore is a simple abstraction layer on top of other vectorization libraries. It provides an architecture-independent API for expressing vector operations on data. Code written with this API can then be dispatched to one of several backends implemented using libraries like Vc, UME::SIMD, or a scalar implementation. This allows one to get the best performance on platforms supported by Vc and UME::SIMD without losing portability to unsupported architectures like PowerPC, for example, where the scalar backends can be used instead without requiring changes in user code. Another advantage is that, unlike with compiler intrinsics, the same code can be compiled for SSE, AVX2, AVX512, etc, without modifications. With the addition of new backends, such as the new backend based on C++20 and std::experimental::simd, users can automatically take advantage of new features and better performance. This backend supports AVX512 on Intel/AMD64 and NEON on ARM/ARM64, with best performance in most cases. However, it does require compiling code in C++20 mode, which may not always be possible, so there is still an advantage in using it via VecCore's implementation to have a fallback when C++20 is not avaialble. %package devel Summary: Development files for %{name} %description devel The %{name}-devel package contains libraries and header files for developing applications that use %{name}. %prep %forgeautosetup -p1 %build %cmake \ -GNinja \ -DCMAKE_BUILD_TYPE=Release \ -DBUILD_TESTING=ON \ %cmake_build %install %cmake_install %if %{with check} %check %ctest %endif %files devel %license %doc README.md %{_includedir}/VecCore/ %dir %{_libdir}/cmake/VecCore %{_libdir}/cmake/VecCore/*.cmake %changelog %autochangelog