public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Filipe Rosset <filiperosset@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/clpeak] rawhide: fix FTBFS on i686 32-bit arch
Date: Sat, 13 Jun 2026 18:30:38 GMT	[thread overview]
Message-ID: <178137543839.1.3381275423214774171.rpms-clpeak-49cab4fda9e6@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/clpeak
            Branch : rawhide
            Commit : 49cab4fda9e63b0dd1062ae758149f26d1b0aea3
            Author : Filipe Rosset <filiperosset@fedoraproject.org>
            Date   : 2026-06-13T15:30:14-03:00
            Stats  : +44/-1 in 2 file(s)
            URL    : https://src.fedoraproject.org/rpms/clpeak/c/49cab4fda9e63b0dd1062ae758149f26d1b0aea3?branch=rawhide

            Log:
            fix FTBFS on i686 32-bit arch

Signed-off-by: Filipe Rosset <filiperosset@fedoraproject.org>

---
diff --git a/clpeak-fix-amx-32bit.patch b/clpeak-fix-amx-32bit.patch
new file mode 100644
index 0000000..b6eeb51
--- /dev/null
+++ b/clpeak-fix-amx-32bit.patch
@@ -0,0 +1,42 @@
+diff -urN a/src/cpu/CMakeLists.txt b/src/cpu/CMakeLists.txt
+--- a/src/cpu/CMakeLists.txt	2026-06-10 13:49:05.000000000 -0300
++++ b/src/cpu/CMakeLists.txt	2026-06-13 15:18:12.788239406 -0300
+@@ -220,7 +220,7 @@
+             if(_clpeak_f_fp16x)
+                 clpeak_add_isa_tu(avx512fp16 ${_avx512_core} ${_clpeak_gnuflag}-mavx512fp16)
+             endif()
+-            if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
++            if(CMAKE_SYSTEM_NAME STREQUAL "Linux" AND CMAKE_SIZEOF_VOID_P EQUAL 8)
+                 set(_amx ${_avx512_core} -mamx-tile -mamx-int8 -mamx-bf16)
+                 check_cxx_compiler_flag("${_amx}" _clpeak_f_amx)
+                 if(_clpeak_f_amx)
+diff -urN a/src/cpu/cpu_kernels_impl.h b/src/cpu/cpu_kernels_impl.h
+--- a/src/cpu/cpu_kernels_impl.h	2026-06-10 13:49:05.000000000 -0300
++++ b/src/cpu/cpu_kernels_impl.h	2026-06-13 15:18:17.943243777 -0300
+@@ -19,7 +19,7 @@
+ #define CLPEAK_ISA_NAME_STR "scalar"
+ #endif
+ 
+-#if (defined(__AMX_INT8__) || defined(__AMX_BF16__)) && defined(__linux__)
++#if (defined(__AMX_INT8__) || defined(__AMX_BF16__)) && defined(__linux__) && defined(__x86_64__)
+ #include <immintrin.h>
+ #endif
+ 
+@@ -421,7 +421,7 @@
+ 
+ // ---- Matrix engine: int8 (AMX / SMMLA) and bf16 (AMX / BFMMLA) -------------
+ // ops are PER-k; the table multiplies by INNER (the chain loops INNER per outer).
+-#if defined(__AMX_INT8__) && defined(__linux__)
++#if defined(__AMX_INT8__) && defined(__linux__) && defined(__x86_64__)
+ #define CPU_MAT_INT8_KERNEL 1
+ static constexpr double MAT_I8_OPS_PER_K = 4.0 * 16 * 16 * 64 * 2;
+ static thread_local bool g_amxI8Cfg = false;
+@@ -476,7 +476,7 @@
+ }
+ #endif
+ 
+-#if defined(__AMX_BF16__) && defined(__linux__)
++#if defined(__AMX_BF16__) && defined(__linux__) && defined(__x86_64__)
+ #define CPU_MAT_FP_KERNEL 1
+ static constexpr double MAT_FP_OPS_PER_K = 4.0 * 16 * 16 * 32 * 2;
+ static thread_local bool g_amxBf16Cfg = false;

diff --git a/clpeak.spec b/clpeak.spec
index 5d1c150..3eae609 100644
--- a/clpeak.spec
+++ b/clpeak.spec
@@ -5,6 +5,7 @@ Summary:    Measure the peak achievable performance of GPU compute devices
 License:    Apache-2.0
 URL:        https://github.com/krrishnarraj/%{name}
 Source:     %{url}/archive/%{version}/%{name}-%{version}.tar.gz
+Patch:      clpeak-fix-amx-32bit.patch
 
 BuildRequires: cmake
 BuildRequires: gcc
@@ -31,7 +32,7 @@ scheduling, extension exposure) become visible alongside the raw peak
 numbers.
 
 %prep
-%autosetup
+%autosetup -p1
 
 
 %build

                 reply	other threads:[~2026-06-13 18:30 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178137543839.1.3381275423214774171.rpms-clpeak-49cab4fda9e6@fedoraproject.org \
    --to=filiperosset@fedoraproject.org \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox