From 4832ff9e544c6b8b25f5127507448cc2a60dd7f9 Mon Sep 17 00:00:00 2001 From: Vladislav Dronov Date: Thu, 23 Apr 2026 16:44:33 +0200 Subject: [PATCH] Initial import of intel-qpl 1.9.0 Import of intel-qpl-1.9.0 @ 1813cced Add intel-qpl-tests subpackage Add OSCI tests Resolves: RHEL-47243 Signed-off-by: Vladis Dronov --- .gitignore | 1 + intel-qpl.spec | 95 +++++++++++++++++++++++++++++++++++++++++++++++ qpl-accel.patch | 7 ++++ qpl-tests.patch | 76 +++++++++++++++++++++++++++++++++++++ qpl-werror.patch | 11 ++++++ sources | 1 + tests/functest.sh | 5 +++ tests/tests.yml | 13 +++++++ 8 files changed, 209 insertions(+) create mode 100644 intel-qpl.spec create mode 100644 qpl-accel.patch create mode 100644 qpl-tests.patch create mode 100644 qpl-werror.patch create mode 100644 sources create mode 100755 tests/functest.sh create mode 100644 tests/tests.yml diff --git a/.gitignore b/.gitignore index e69de29..8284b6e 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/intel-qpl-*.tar.gz diff --git a/intel-qpl.spec b/intel-qpl.spec new file mode 100644 index 0000000..9a9f989 --- /dev/null +++ b/intel-qpl.spec @@ -0,0 +1,95 @@ +Name: intel-qpl +Version: 1.9.0 +Release: %autorelease +Summary: Intel Query Processing Library + +License: MIT +URL: https://github.com/intel/qpl +Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz + +Patch0: qpl-accel.patch +Patch1: qpl-tests.patch +Patch2: qpl-werror.patch + +BuildRequires: cmake >= 3.1 +BuildRequires: gcc-c++ +BuildRequires: gtest-devel +BuildRequires: libuuid-devel +BuildRequires: libtsan +BuildRequires: nasm + +ExclusiveArch: x86_64 + +%description +The Intel Query Processing Library (Intel QPL) is an open-source library to +provide high-performance query processing operations on Intel CPUs. Intel QPL +is aimed to support capabilities of the new Intel In-Memory Analytics +Accelerator (Intel IAA) available on Next Generation Intel Xeon Scalable +processors, codenamed Sapphire Rapids processor, such as very high throughput +compression and decompression combined with primitive analytic functions, as +well as to provide highly-optimized SW fallback on other Intel CPUs. +Intel QPL primarily targets applications such as big-data and in-memory +analytic databases. + +%package devel +Summary: Development files for %{name} +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: accel-config-libs + +%description devel +The %{name}-devel package contains libraries and header files for +applications that use %{name}. + +%package tests +Summary: Test applications that use %{name} +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: gtest + +%description tests +The %{name}-tests package contains test datasets, functional +and cross-test applications that use and test %{name}. + +%prep +%autosetup -p1 -n qpl-%{version} +# Continue to use Gtest 1.14.0 instead of 1.15.2 +sed -i -e 's|GTEST_INTERNAL_ATTRIBUTE_MAYBE_UNUSED|GTEST_ATTRIBUTE_UNUSED_|g' tools/tests/common/test_cases.hpp + +%build +%cmake \ + -DCMAKE_BUILD_TYPE=RelWithDebInfo \ + -DDYNAMIC_LOADING_LIBACCEL_CONFIG=ON \ + -DQPL_LIBRARY_TYPE=SHARED \ + -DSANITIZE_THREADS=ON \ + -DQPL_BUILD_TESTS=ON \ + -DQPL_BUILD_EXAMPLES=OFF +%cmake_build + +%install +%cmake_install + +%check +# Change to "--gtest_filter=ta_unit*" for a longer and more comprehensive unit test (software path) +%__cmake_builddir/tools/tests/functional/qpl-func-tests --dataset=tools/testdata/ --gtest_filter=ta_c_api_async_multiple_jobs_submit.*:ta_c_api_integrity_control.*:ta_c_api_crc64.* + +%files +%license LICENSE +%doc README.md +%{_libdir}/libqpl.so.1 +%{_libdir}/libqpl.so.%{version} + +%files devel +%{_includedir}/qpl +%{_datadir}/intel-qpl/configs +%{_datadir}/intel-qpl/scripts +%{_libdir}/libqpl.so +%{_libdir}/cmake/QPL +%{_libdir}/pkgconfig/qpl.pc + +%files tests +%doc doc/source/documentation/get_started_docs/testing.rst +%{_datadir}/intel-qpl/testdata +%{_bindir}/qpl-func-tests +%{_bindir}/qpl-cross-tests + +%changelog +%autochangelog diff --git a/qpl-accel.patch b/qpl-accel.patch new file mode 100644 index 0000000..204a04d --- /dev/null +++ b/qpl-accel.patch @@ -0,0 +1,7 @@ +--- a/tools/scripts/accel_conf.sh 2025-12-02 14:42:56.000000000 +0100 ++++ b/tools/scripts/accel_conf.sh 2025-12-02 14:42:56.000000000 +0100 +@@ -1,3 +1,4 @@ ++#!/bin/bash + # ========================================================================== + # Copyright (C) 2022 Intel Corporation + # diff --git a/qpl-tests.patch b/qpl-tests.patch new file mode 100644 index 0000000..4463974 --- /dev/null +++ b/qpl-tests.patch @@ -0,0 +1,76 @@ +--- a/tools/CMakeLists.txt 2025-12-02 14:42:56.000000000 +0100 ++++ b/tools/CMakeLists.txt 2025-12-02 14:42:56.000000000 +0100 +@@ -19,7 +19,7 @@ + add_subdirectory(utils) + set(TEMP_CMAKE_CXX_CLANG_TIDY ${CMAKE_CXX_CLANG_TIDY}) + set(CMAKE_CXX_CLANG_TIDY "") +- add_subdirectory(third-party/google-test EXCLUDE_FROM_ALL) ++ # add_subdirectory(third-party/google-test EXCLUDE_FROM_ALL) + set(CMAKE_CXX_CLANG_TIDY ${TEMP_CMAKE_CXX_CLANG_TIDY}) + add_subdirectory(tests) + if (UNIX) +@@ -27,18 +27,21 @@ if (QPL_BUILD_TESTS) + SET(BENCHMARK_ENABLE_TESTING OFF CACHE BOOL "" FORCE) + set(TEMP_CMAKE_CXX_CLANG_TIDY ${CMAKE_CXX_CLANG_TIDY}) + set(CMAKE_CXX_CLANG_TIDY "") +- add_subdirectory(third-party/benchmark EXCLUDE_FROM_ALL) ++ # add_subdirectory(third-party/benchmark EXCLUDE_FROM_ALL) + set(CMAKE_CXX_CLANG_TIDY ${TEMP_CMAKE_CXX_CLANG_TIDY}) +- add_subdirectory(benchmarks) ++ # add_subdirectory(benchmarks) + endif () + endif () + + add_subdirectory(pkg-config) + + install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/configs +- DESTINATION share/${CMAKE_PROJECT_NAME} ++ DESTINATION share/intel-qpl + COMPONENT RUNTIME) + install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/scripts +- DESTINATION share/${CMAKE_PROJECT_NAME} ++ DESTINATION share/intel-qpl + COMPONENT RUNTIME + FILE_PERMISSIONS USE_SOURCE_PERMISSIONS) ++install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/testdata ++ DESTINATION share/intel-qpl ++ COMPONENT RUNTIME) +--- a/tools/tests/functional/CMakeLists.txt 2025-12-02 14:42:56.000000000 +0100 ++++ b/tools/tests/functional/CMakeLists.txt 2025-12-02 14:42:56.000000000 +0100 +@@ -22,6 +22,8 @@ add_executable(tests main.cpp + $) + + qpl_set_common_target_settings(tests) ++set_target_properties(tests PROPERTIES ++ OUTPUT_NAME qpl-func-tests) + + get_property(LIB_DEPS GLOBAL PROPERTY QPL_LIB_DEPS) + +@@ -41,6 +43,9 @@ target_compile_definitions(tests + target_compile_options(tests + PRIVATE $) + ++install(TARGETS tests ++ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) ++ + # Test groups that run under target: make test + + # Smoke tests are a group of small number of tests that can run in a few seconds on any HW. +--- a/tools/tests/cross_tests/CMakeLists.txt 2025-12-02 14:42:56.000000000 +0100 ++++ b/tools/tests/cross_tests/CMakeLists.txt 2025-12-02 14:42:56.000000000 +0100 +@@ -14,6 +14,8 @@ file(GLOB SOURCES *.cpp) + add_executable(cross_tests ${SOURCES}) + + qpl_set_common_target_settings(cross_tests) ++set_target_properties(cross_tests PROPERTIES ++ OUTPUT_NAME qpl-cross-tests) + + get_target_property(QPL_SOURCE_DIR qpl SOURCE_DIR) + +@@ -31,3 +33,6 @@ target_link_libraries(cross_tests + + target_compile_definitions(cross_tests PRIVATE $) + target_compile_options(cross_tests PRIVATE $) ++ ++install(TARGETS cross_tests ++ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) diff --git a/qpl-werror.patch b/qpl-werror.patch new file mode 100644 index 0000000..fb374f0 --- /dev/null +++ b/qpl-werror.patch @@ -0,0 +1,11 @@ +--- a/cmake/target_settings.cmake 2025-12-02 14:42:56.000000000 +0100 ++++ b/cmake/target_settings.cmake 2025-12-02 14:42:56.000000000 +0100 +@@ -119,7 +119,7 @@ function (qpl_set_language_standards tar + endforeach () + endfunction () + +-option(QPL_TREAT_WARNINGS_AS_ERRORS "Treat all compiler warnings as errors" ON) ++option(QPL_TREAT_WARNINGS_AS_ERRORS "Treat all compiler warnings as errors" OFF) + + # Enables all reasonable warnings for a target with the given name ${target_name}. + # diff --git a/sources b/sources new file mode 100644 index 0000000..3380a15 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (intel-qpl-1.9.0.tar.gz) = 4a9c51d6866a517cd6b75f2ec431b00a3b3292e3b15b2a128ccafd807c4b5212b55f05f37dee872ff35df1c0764aed694281145122e63c0918281ad17ce01754 diff --git a/tests/functest.sh b/tests/functest.sh new file mode 100755 index 0000000..71c2cfb --- /dev/null +++ b/tests/functest.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +# This is a software path test, it can be run on a machine without IAA hardware +rpm -qa gtest\* intel-qpl\* +qpl-func-tests --dataset=/usr/share/intel-qpl/testdata/ --gtest_filter=ta_unit\* diff --git a/tests/tests.yml b/tests/tests.yml new file mode 100644 index 0000000..518ddfb --- /dev/null +++ b/tests/tests.yml @@ -0,0 +1,13 @@ +--- +- hosts: localhost + roles: + - role: standard-test-basic + tags: + - classic + tests: + - functest: + dir: . + run: functest.sh + required_packages: + - gtest + - intel-qpl-tests