arm64 SME2 (Apple M4): SGEMM/DGEMM well below the hardware, level-3 routines on NEON, M4 Pro not detected
Les mainteneurs répondent en général sous 1 jour
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Accessibilité débutants
- 35/100
- Type d'issue
- Bug
- Clarté
- Plutôt claire
- Activité
- Active
- Stack technique
- c
- Domaine
- backend, performance
Piste de recherche
Start with the SME [s/d]GEMM kernels, the level-3 driver, and getarch, using the references to issues #5971 and #5011 for existing context. Reproduce the reported M4 Pro benchmarks and detection behavior; done means M4 Pro is recognized and the affected level-3 routines use appropriate SME paths with performance approaching the stated hardware and Accelerate comparisons.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
On Apple M4 (SME2, 512-bit streaming vector length), develop (63d7f22) leaves most of the SME unit unused:
-
SGEMM/DGEMM:
sme_[sd]gemm_kernel(#5971) runs at about 0.6x of Accelerate on one thread, and on one
thread whatever the thread count, while the M4 Pro has two SME units (one per performance cluster).
fp32 geometric means over the 24 workloads of Deng et al. (arXiv:2512.21473), row-major / column-major, GFLOPS:Accelerate develop SGEMM, 1 thread 1127 / 1185 707 / 766 SGEMM, default threads 2364 / 2445 702 / 766 DGEMM, 1 thread 321 / 344 275 / 283 -
SYMM, SYRK, SYR2K, TRMM, TRSM run through the level-3 driver on NEON kernels: about 100-115 GFLOPS in fp32
and 53-58 in fp64 at n = 1024 on one thread, against 791-1758 and 265-433 for Accelerate. The SME kernel cannot
simply be plugged into the driver, because SYMM/TRMM share the GEMM unroll sizes (where #5011 stopped). -
Detection: the M4 Pro (
hw.cpufamily0x17d5b93a) is not recognised bygetarch, so a build without
TARGETfalls back to ARMV8 without any SME code.
Measured on an M4 Pro, macOS 27, Apple clang 21; harness and raw data in https://github.com/tesch1/mtgemm-a.
Prepared with AI coding assistance.
- Langage dominant
- C
- Étoiles
- 7.6k
- Forks
- 1.7k
- Merge moyen
- 1 j 8 h
- PR mergées (30 j)
- 48
Préparer son environnement
Ce projet ne fournit ni conteneur de développement, ni Dockerfile, ni guide de contribution : l'installation est à votre charge. Commencez par son README, et consultez notre guide de la première contribution pour les étapes générales.
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de OpenMathLib/OpenBLAS
-
Difficulté 3/5 1-2 jours Accessibilité débutants 68/100
OpenMathLib/OpenBLAS#6069 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Missing cgroup awarenessOuverte
Difficulté 4/5 3-5 jours Accessibilité débutants 52/100
OpenMathLib/OpenBLAS#6059 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 4/5 3-5 jours Accessibilité débutants 48/100
OpenMathLib/OpenBLAS#6029 · 21 commentaires ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 3/5 1-2 jours Accessibilité débutants 68/100
OpenMathLib/OpenBLAS#6028 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 4/5 3-5 jours Accessibilité débutants 35/100
OpenMathLib/OpenBLAS#6005 · 21 commentaires · 2 réactions ·
Les mainteneurs répondent en général sous 1 jour
Toutes les issues de OpenMathLib/OpenBLAS
Issues similaires
-
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
python-pillow/Pillow#10087 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
OpenPrinting/cups#1729 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 84/100
awslabs/amazon-kinesis-video-streams-webrtc-sdk-c#2406 ·
Les mainteneurs répondent en général sous 2 jours
-
Difficulté 2/5 1-3 heures Accessibilité débutants 86/100
DaveGamble/cJSON#1094 ·
-
status:needs-triage
Difficulté 2/5 1-3 heures Accessibilité débutants 90/100
PX4/PX4-Autopilot#28923 ·
Les mainteneurs répondent en général sous 1 jour